[Devel] table names for ACC module

Bogdan-Andrei Iancu bogdan at voice-system.ro
Thu Oct 19 14:43:26 CEST 2006

Hi Victor,

it is an interesting idea - please upload it on the tracker, in the 
Feature Request section to see if some of the developers consider it for 

Usually my opinion is to keep things as simple as possible on the proxy 
(as it is a key component) and try to implement the complex stuff 
outside, if possible. Have you consider writing a small shell script to 
do table rotation at the end of the day ? Like openser writes in the 
same table and, at the end of the day, the script moves all records a 
custom named table.


Victor Gamov wrote:

> Hi guys!
> I use OpenSER a bit of time but I have many experience in VoIP and 
> billing production.
> Now we use ACC module to write accounting info into DB directly (not 
> through RADIUS/DIAMETER) and then we use accounting table to produce 
> CDR for our billing software.
> Now we have many records in one table but it's very useful if we can 
> write accounting info into different tables changed periodically by 
> the time principle.
> I propose to use meta-characters in table-name parameter for this 
> purpose.
> We can use meta-characters like strftime() for example, so if I write 
> in config something like
>modparam("acc", "db_table_acc", "myacc_table-%Y-%m-%d")
> I have get one accounting table per day.
> It's really very flexible and very useful in many situations.
> One complexity which I see now -- we must have CREATE TABLE statement 
> in OpenSER.  But if OpenSER write accounting into some external 
> database.table (not default openser.acc) external process can create 
> this table or (more correctly) we can have one more ACC module 
> parameter like "db_table_acc_create" and use it as SQL statement to 
> create table.
> -- 
> CU,
> Victor Gamov
>Devel mailing list
>Devel at openser.org

More information about the Devel mailing list