[Serusers] cpl_init: mandatory parameter

Aisling O'Driscoll ashling.odriscoll at cit.ie
Wed Apr 13 15:57:22 CEST 2005


Thanks Bogdan,

I checked the readme and discovered modparam("cpl-c", "cpl_dtd_file",
"/tmp/ser-0.9.0/modules/cpl-c/cpl-06.dtd") worked for me. My ser.cfg
is identical to the one on the ONSIP site. I was wondering if I could
confirm something?...Should the cpl prcoessing be dealt with in the
route[X] sections or before?? 

i.e. eg:Currently I have:

if (uri==myself){
    if (method=="INVITE"){
        route(3);
        break;
    } else if (method == "REGISTER"){
        route(2);
        break;
    };
    .....

Would it be appropriate to change this to??:

if (uri==myself){
    if (method=="INVITE"){
        if (!t_newtran()){
           break;
        }
        if (!cpl_run_script("incoming")){
           t_reply("500", "CPL execution failed");
        }

        route(3);
        break;
    } else if (method == "REGISTER"){
        cpl_process_register();
        route(2);
        break;
    };
    .....

Or should it be dealt with in the route[X] sections?...Also is there
example ser.cfg cpl script information or guidelines anywhere that
you know of?? I'd appreciate any information.

Kindest regards,
Aisling.

>
>---- Original Message ----
>From: bogdan at voice-system.ro
>To: ashling.odriscoll at cit.ie
>Subject: Re: [Serusers] cpl_init: mandatory parameter
>Date: Tue, 12 Apr 2005 18:43:48 +0200
>
>>cpl_dtd_file is the complete path (including filename)of the DTD
>file - 
>>you can find this file in cpl-c module directory - for info about
>module 
>>param, take a look into module README.
>>
>>bogdan
>>
>>Aisling O'Driscoll wrote:
>>
>>>That worked Bogdon,Thank you, I also added:
>>>modparam ("cpl-c", "cpl_table", "cpl")
>>>
>>>Now it requires the cpl_dtd_file - However I am not sure what path
>>>here: i.e.
>>>modparam("cpl-c", "cpl_dtd_file", "whatpath?")
>>>
>>>Is there a usual directory where this can be found?
>>>
>>>Regards,
>>>Aisling
>>>
>>>  
>>>
>>>>---- Original Message ----
>>>>From: bogdan at voice-system.ro
>>>>To: vivcurran at yahoo.co.uk
>>>>Subject: Re: [Serusers] cpl_init: mandatory parameter "DB_URL"
>found
>>>>empty
>>>>Date: Tue, 12 Apr 2005 18:05:02 +0200
>>>>
>>>>    
>>>>
>>>>>sorry, in cpl-c the parameter is called "cpl_db" - I will change
>the
>>>>>      
>>>>>
>>>>>error message to state the proper parameter name. (db_url ->
>cpl_db)
>>>>>
>>>>>bogdan
>>>>>
>>>>>
>>>>>Vivienne Curran wrote:
>>>>>
>>>>>      
>>>>>
>>>>>>Bogdan,
>>>>>> 
>>>>>>I set 
>>>>>>modparam("cpl-c","db_url","mysql://root:password@localhost/ser")
>, 
>>>>>>however when i tried to restart SER I got:
>>>>>> 
>>>>>>set_mod_param_regex: parameter <db_url> not found in module
>>>>>>        
>>>>>>
>>>><cpl-c>
>>>>    
>>>>
>>>>>>parse error (87,20-21): Can't set module parameter
>>>>>> 
>>>>>>I tried db_url in upper case also. An I incoorect in thinking
>that
>>>>>>        
>>>>>>
>>>>the 
>>>>    
>>>>
>>>>>>module should load without this anyway?
>>>>>> 
>>>>>>Regards,
>>>>>>Aisling.
>>>>>>
>>>>>>*/Bogdan-Andrei Iancu <bogdan at voice-system.ro>/* wrote:
>>>>>>
>>>>>>    you have to set the db_url parameter pointing to a DB
>>>>>>        
>>>>>>
>>>>connection -
>>>>    
>>>>
>>>>>>    default is NULL. For example:
>>>>>>    modparam("cpl-c","db_url","mysql://ser:heslo@localhost/ser")
>>>>>>
>>>>>>    bogdan
>>>>>>
>>>>>>    Aisling O'Driscoll wrote:
>>>>>>
>>>>>>    >Hello,
>>>>>>    >
>>>>>>    >I am using ser 0.9.0. When I try to load the cpl module
>e.g.
>>>>>>    >loadmodule "/opt/ser/lib/ser/modules/cpl-c.so", and restart
>>>>>>        
>>>>>>
>>>>ser, I
>>>>    
>>>>
>>>>>>    >get the following error:
>>>>>>    >
>>>>>>    >ERROR:cpl_init: mandatory parameter "DB_URL" found empty
>>>>>>    >init_mod(): Error while initializing module cpl-c
>>>>>>    >
>>>>>>    >When I check in /opt/ser/lib/ser/modules, the cpl-c module
>si
>>>>>>        
>>>>>>
>>>>there.
>>>>    
>>>>
>>>>>>    >Does anyone have any clue how this can be resolved?
>>>>>>    >
>>>>>>    >Thank you,
>>>>>>    >Aisling.
>>>>>>        
>>>>>>
>>>  
>>>
>>
>>
>>-------------------Legal 
>Disclaimer---------------------------------------
>>
>>The above electronic mail transmission is confidential and intended
>only for the person to whom it is addressed. Its contents may be
>protected by legal and/or professional privilege. Should it be
>received by you in error please contact the sender at the above
>quoted email address. Any unauthorised form of reproduction of this
>message is strictly prohibited. The Institute does not guarantee the
>security of any information electronically transmitted and is not
>liable if the information contained in this communication is not a
>proper and complete record of the message as transmitted by the
>sender nor for any delay in its receipt.
>>
>>



-------------------Legal  Disclaimer---------------------------------------

The above electronic mail transmission is confidential and intended only for the person to whom it is addressed. Its contents may be protected by legal and/or professional privilege. Should it be received by you in error please contact the sender at the above quoted email address. Any unauthorised form of reproduction of this message is strictly prohibited. The Institute does not guarantee the security of any information electronically transmitted and is not liable if the information contained in this communication is not a proper and complete record of the message as transmitted by the sender nor for any delay in its receipt.




More information about the sr-users mailing list