Tap here to compare the top VoIP providersTap here to hide the top VoIP Providers
Asterisk CDR csv handling
How a company handles CDR files from many Asterisk serversWe have a cron job that moves master.csv to subdir/<timestamp>.csv and then tries to parse and delete all csvs in that directory. The reasons we did this were
- We wanted to store more data in the database without having to change source code. For example, we have 45 asterisk servers writing to one cdr database so it's nice to have a field in the database telling us which server input that row.
- Our database server is in another office so when the network goes down or there is a power outage somewhere, we no longer have this huge one point of failure for all of our remote phone servers. The csvs just keep piling up until a valid connection to the database can be restored.
To my knowledge asterisk doesn't keep master.csv open between writes and when we've moved it we never had a problem. Asterisk simply creates a new master.csv the next time a write occurs.
David Carr, november 2003
Created by: oej, Last modification: Mon 17 of Nov, 2003 (21:17 UTC)
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+