diff options
author | murf <murf@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-04-05 22:35:11 +0000 |
---|---|---|
committer | murf <murf@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-04-05 22:35:11 +0000 |
commit | 8785f0c00dcf84a0e7f4504e6a79488c340725d2 (patch) | |
tree | e4e6831d53d1f91bef650de4e9ba49ea2bb846b3 /configs | |
parent | ae9f206ab85643d777f554b724a3de6ab2bc4fe9 (diff) |
Added some clarification to the example configs for CDRs, on how to select a backend. Also, made cdr-csv the default if you 'make samples', and no other changes.
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@60323 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'configs')
-rw-r--r-- | configs/cdr.conf.sample | 77 | ||||
-rw-r--r-- | configs/cdr_custom.conf.sample | 8 |
2 files changed, 79 insertions, 6 deletions
diff --git a/configs/cdr.conf.sample b/configs/cdr.conf.sample index 4e4c3d43c..9a5eb8a27 100644 --- a/configs/cdr.conf.sample +++ b/configs/cdr.conf.sample @@ -56,10 +56,79 @@ ; retrieved inside of of this extension. ;endbeforehexten=no -;[csv] -;usegmtime=yes ;log date/time in GMT -;loguniqueid=yes ;log uniqueid -;loguserfield=yes ;log user field +; +; +; CHOOSING A CDR "BACKEND" (what kind of output to generate +; +; To choose a backend, you have to make sure either the right category is +; defined in this file, or that the appropriate config file exists, and has the +; proper definitions in it. If there are any problems, usually, the entry will +; silently ignored, and you get no output. +; +; Also, please note that you can generate CDR records in as many formats as you +; wish. If you configure 5 different CDR formats, then each event will be logged +; in 5 different places! In the example config files, all formats are commented +; out except for the cdr-csv format. +; +; Here are all the possible back ends: +; +; csv, custom, manager, odbc, pgsql, radius, sqlite, tds +; (also, mysql is available via the asterisk-addons, due to licensing +; requirements) +; (please note, also, that other backends can be created, by creating +; a new backend module in the source cdr/ directory!) +; +; Some of the modules required to provide these backends will not build or install +; unless some dependency requirements are met. Examples of this are pgsql, odbc, +; etc. If you are not getting output as you would expect, the first thing to do +; is to run the command "make menuselect", and check what modules are available, +; by looking in the "2. Call Detail Recording" option in the main menu. If your +; backend is marked with XXX, you know that the "configure" command could not find +; the required libraries for that option. +; +; To get CDRs to be logged to the plain-jane /var/log/asterisk/cdr-csv/Master.csv +; file, define the [csv] category in this file. No database necessary. The example +; config files are set up to provide this kind of output by default. +; +; To get custom csv CDR records, make sure the cdr-custom.config file +; is present, and contains the proper [mappings] section. The advantage to +; using this backend, is that you can define which fields to output, and in +; what order. By default, the example configs are set up to mimic the cdr-csv +; output. If you don't make any changes to the mappings, you are basically generating +; the same thing as cdr-csv, but expending more CPU cycles to do so! +; +; To get manager events generated, make sure the cdr_manager.config file exists, +; and the [general] section is defined, with the single variable' enabled = yes'. +; +; for odbc, make sure all the proper libs are installed, that "make menuselect" +; shows that the modules are available, and the cdr_odbc.conf file exists, and +; has a [global] section with the proper variables defined. +; +; for pgsql, make sure all the proper libs are installed, that "make menuselect" +; shows that the modules are available, and the cdr_pgsql.conf file exists, and +; has a [global] section with the proper variables defined. +; +; for logging to radius databases, make sure all the proper libs are installed, that +; "make menuselect" shows that the modules are available, and the [radius] +; category is defined in this file, and in that section, make sure the 'radiuscfg' +; variable is properly pointing to an existing radiusclient.conf file. +; +; for logging to sqlite databases, make sure the 'cdr.db' file exists in the log directory, +; which is usually /var/log/asterisk. Of course, the proper libraries should be available +; during the 'configure' operation. +; +; for tds logging, make sure the proper libraries are available during the 'configure' +; phase, and that cdr_tds.conf exists and is properly set up with a [global] category. +; +; Also, remember, that if you wish to log CDR info to a database, you will have to define +; a specific table in that databse to make things work! See the doc directory for more details +; on how to create this table in each database. +; + +[csv] +usegmtime=yes ;log date/time in GMT +loguniqueid=yes ;log uniqueid +loguserfield=yes ;log user field ;[radius] ;usegmtime=yes ;log date/time in GMT diff --git a/configs/cdr_custom.conf.sample b/configs/cdr_custom.conf.sample index 4af17c37b..8bc2cb34e 100644 --- a/configs/cdr_custom.conf.sample +++ b/configs/cdr_custom.conf.sample @@ -1,6 +1,10 @@ ; ; Mappings for custom config file ; -[mappings] -Master.csv => "${CDR(clid)}","${CDR(src)}","${CDR(dst)}","${CDR(dcontext)}","${CDR(channel)}","${CDR(dstchannel)}","${CDR(lastapp)}","${CDR(lastdata)}","${CDR(start)}","${CDR(answer)}","${CDR(end)}","${CDR(duration)}","${CDR(billsec)}","${CDR(disposition)}","${CDR(amaflags)}","${CDR(accountcode)}","${CDR(uniqueid)}","${CDR(userfield)}" +; to get your csv output in a format tailored to your liking, uncomment the following +; and look for the output in the cdr-custom/Master.csv file (usually in /var/log/asterisk). +; +; +;[mappings] +;Master.csv => "${CDR(clid)}","${CDR(src)}","${CDR(dst)}","${CDR(dcontext)}","${CDR(channel)}","${CDR(dstchannel)}","${CDR(lastapp)}","${CDR(lastdata)}","${CDR(start)}","${CDR(answer)}","${CDR(end)}","${CDR(duration)}","${CDR(billsec)}","${CDR(disposition)}","${CDR(amaflags)}","${CDR(accountcode)}","${CDR(uniqueid)}","${CDR(userfield)}" |