このページは役立ちましたか?

CDRレポートについて

    Are CDR records ever deleted?


    No.  Fonality does not remove your CDR reports for any reason ever.  They 'live' on your server, and the only mitigating factor in CDR reports is the total space on your hard drive available for storage.  If your server takes 10,000 calls per day for 5 years straight, these files may begin to grow large and consume space on your hard drive unnecessarily.  In this case, you may wish to offload the files into CSV format and store them on your company SAN.

    Export into CSV


    This feature requires Professional/Enterprise edition or higher.

    Most of the time, you'll use the Web Admin Panel > Reporting > cdr reports tab to export call logs for your trixbox Pro server, as detailed here:

    Saving the data to a file

    Internet Explorer:

    1. Reporting > CDR reports.  Check CSV checkbox, select the desired ranges, dates, display options.  Run report.
    2. CTRL+A to select all.  CTRL+C to copy.
    3. Open up notepad.  CTRL+V to paste.
    4. File > Save as...  I suggest a .csv extension.  For example, "filename.csv"
    5. You must change type to "all files" before saving.

     

    Firefox:

    1. Reporting > CDR reports.  Check CSV checkbox, select the desired ranges, dates, display options.  Run report.
    2. Right-click on page, select "This frame" > "Same frame as..."
    3. I suggest a .csv (comma-separated values) extension, to make it clearer to Excel.

     

    You can read this information into a program like Microsoft Excel or Crystal Reports to sort and analyze the data.

    Locate the RAW data


    This document describes how to find the raw CDR (Call Data Record) files recorded by your trixbox Pro . These files are needed if you plan to import your call log information into a database in an automated fashion. The files are automatically created by the FONcore software on the trixbox Pro system, and are the same data that Fonality uses to update your call logs in the trixbox Pro Admin Panel.

    Directory on your trixbox Pro

    You can find all of your CDR records grouped by week on your server in the following directory:

    /var/log/asterisk/cdr-csv/07-10-01
    

    (the date - 07-10-01 - corresponds to YY-MM-DD and a new directory is created on Monday of each week)

    This directory may contain thousands of files, so don’t simply ‘cd’ to the directory and run ‘ls’. You might need to wait several minutes for your terminal to finish printing all the filenames. If you make that mistake, you will need to use CTRL+C to abort the ‘ls’ output.

    How are files named?

    The files in the directory are named like this:

    Master.csv.1114459934


    The file named ‘Master.csv’ is the ACTIVE file, and should not be opened and read. If you try to read the active file, it may change while you are reading it. The Master.csv.xxxxxxxxxx files are the INACTIVE files that have already been rotated by the system on a 5 minute interval, and will no longer change. The integer string on the end of the filename represents the UNIX time that the file was rotated. This is the number of seconds elapsed since Jan 1, 1970. You can convert this to a human readable date like this:

    [root@pbx0000 ~]# perl -MTime::localtime -e 'print ctime(1114459934) . "\n";'

    Mon Apr 25 16:12:14 2005


    As you can see from the above example, the number corresponds to the date “Mon Apr 25 16:12:14 2005”.

    What do the contents of files look like?

    The contents of the files will look like this:

    "","7013","913105551212","internal","7013 <7013>","SIP/AABBCCDDEEFF-759f",
    "IAX2/c1006i/1","ResetCDR","w","2006-03-31 17:43:22","2006-03-31 17:43:24",
    "2006-03-31 17:43:26",4,2,"ANSWERED","DOCUMENTATION"


    The above is one line of an example CDR file. Admittedly, this looks rather cryptic. It’s a comma separated values format. The columns are in the following order:

    '''accountcode:''' An account code designation (reserved for future use in trixbox Pro )
    '''src:''' Caller*ID number (string, 80 characters)
    '''dst:''' Destination extension (string, 80 characters)
    '''dcontext:''' Destination context/submenu (string, 80 characters)
    '''clid:''' Caller*ID with text (80 characters)
    '''channel:''' Channel used (80 characters)
    '''dstchannel:''' Destination channel if appropriate (80 characters)
    '''lastapp:''' Last application if appropriate (80 characters)
    '''lastdata:''' Last application data (arguments) (80 characters)
    '''start:''' Start of call (date/time)
    '''answer:''' Answer of call (date/time)
    '''end:''' End of call (date/time)
    '''duration:''' Total time in system, in seconds (integer)
    '''billsec:''' Total time call is up, in seconds (integer)
    '''disposition:''' What happened to the call: ANSWERED, NO ANSWER, BUSY
    '''amaflags:''' Billing flags (reserved for future use in trixbox Pro )


    Note: If you do automate the insertion of this data into a database of your own, and you are confident that it’s working properly, we suggest moving the imported files to another directory on the system to make it easier for your automated program to identify new CDR files to import.
     

    How do I download CDR reports?

     

    Your CDRs are stored in comma-delimited format in the /var/log/asterisk/cdr-csv directory, allowing you to easily import them into a database or report-writer of your choosing.

    These detailed instructions are provided with the following disclaimer:

    Fonality only provides support for the management interface and the PBX itself. These instructions have passed Fonality support peer review before being posted here; however, they are neither endorsed nor supported by Fonality. In short: These instructions are for advanced users and choosing to follow them is at your own risk.

    To retrieve cdr reports from the PBX server for archival purposes
    1.    First the root name and password must be set on the PBXtra .
    2.    Login to the server using username: ip and password: ip.
    3.    When the Fonality options page is displayed, select Option 11 'Set Root Password'.
    4.    The password should be easy to remember and difficult to guess.  Fonality advises using at least a combination of characters and letters in a string a minimum of eight characters. 
    5.    Keep your root password available but secure.

    Once the root password is set the user must connect into the PBX from another location.  This is accomplished using an application such as Winscp freely available at:

    http://winscp.net

    Once this application is installed on another computer, on the same local network, the user must connect into the PBX using the private IP address of the PBX and logging in using the root password that was earlier set.

    Example: the settings using winSCP are:
    Hostname: “Private IP address of your PBx server”
    Port: 22
    Username: root
    Password: “the root password you set previously”

    Once the user is logged into the PBX the files may be downloaded to the remote machine and saved for archival use by the following steps:

    1.    Create a directory/folder on local computer
    2.    Connect to the PBX
    3.    Identify and select the target directory/folder (created in step 1) on the local machine.  If using WinSCP the local machine will be on the left.
    4.    Identify and select the source directory/folder: /var/log/asterisk/der-csv/ on the PBXtra .  If using WinSCP the source machine will be located on the right.
    5.    Download the desired files to be archived.
     

     

    Will you support customization of the CDR system?

    Further use of this information is beyond the scope of the trixbox Pro Annual Support and Maintenance Agreement. You are welcome to perform any integration you wish. However, the support team will not be able to supply you with information in addition to what’s shown above.

     

    このページは役立ちましたか?
    タグ (タグ編集)
    • No tags

    ファイル 0

     
    あなたはコメントを投稿するには ログイン しなければなりません。
    Powered by MindTouch Core