*Hello John:*

Not sure why people are getting confused with logger.conf file and CDRs.
You are the 2nd person who replied with a CDR based response.

So let me try to clarify things here for those who are indeed confused with
CDRs & LOG files.

a)  CDRs are your call detail records - which is usually text based.   You
also have the option to put CDRs in real time database.   In our case CDRs
are available both in text format and mysql format.   The mysql cdr entries
allows us to fine tune & produce reports to our hearts delight.

b) LOGGER - is *not* CDR.    The *logger.conf* contains instructions on how
Asterisk should report logs (verbosity, notice, warnings etc).    The
logger.conf has instructions on what file (or combination of files) should
contain the level of logs (NOT CDR).

Philip Mullis understood the question and was on the right track.   His
suggestion was to run a tail -f with the pipe directive.   We tried it
earlier & it works to an extent.   We faced certain limitations with the
tailing and piping specially when we rotate the logs - details I will skip
here.

The log files generated through logger.conf produces basic text files
containing all the notice, verbose, warning etc. type of messages.   The
challenge is to collect this data in real time into a mysql database for
processing.

*Kind regards,
Reza.*



On Tue, Feb 9, 2010 at 2:14 PM, John Lange <[email protected]> wrote:

> On Tue, 2010-02-09 at 01:30 -0500, Reza - Asterisk Consultant wrote:
> > I have an urgent need to parse log files generated through the
> logger.conf
> > into mysql.    I run a cron job to parse the logs created into mysql
> every
> > 5:00 AM.  However the time has come to get this info real time.
>  Suggestions
> > & ideas are appreciated.
>
> Either this script or a slightly modified version of it should do what
> you need:
>
>
> http://www.johnlange.ca/tech-tips/asterisk/asterisk-cdr-csv-mysql-import-v20/
>
> Regards,
>
> --
> John Lange
> http://www.johnlange.ca
>
>


-- 
Toronto based VoIP / Asterisk Trainer,
I.T. Consultant and Hosted PBX Solutions Provider.
+1-647-476-2067.
http://www.linkedin.com/in/seminar

Reply via email to