[Asterisk-Dev] Mor info about SIP channel

Jason Penton j.penton at ru.ac.za
Wed May 26 02:15:01 MST 2004


Hi all

Does nayone know how to get more specific info about an incoming SIP call
from a SIP proxy like FWD or any other SER proxy. All incmoing calls into my
* box from FWD and other SER proxies have the following channel name:

SIP/-081833b8 or something similar but with the same format (random)

Ie they are quite random. I would far rather have something like
SIP/fwd.pulver.comXXXXXX

Does anyone have any suggestions

Thankls in advance
Jason 

> -----Original Message-----
> From: asterisk-users-admin at lists.digium.com 
> [mailto:asterisk-users-admin at lists.digium.com] On Behalf Of 
> Adam Goryachev
> Sent: 26 May 2004 10:22 AM
> To: asterisk-users at lists.digium.com
> Subject: [Asterisk-Users] cdr_odbc with mysql on a remote server
> 
> I'm trying to add cdr_odbc.so to log my CDR data to a mysql DB. I've
> managed to compile everything, and seem to almost be ready to 
> head home.
> I've added a small debug line to cdr_odbc.c as follows:
>         if((ODBC_res != SQL_SUCCESS) && (ODBC_res !=
> SQL_SUCCESS_WITH_INFO))
>         {
>                 if(option_verbose > 10)
>                         ast_verbose( VERBOSE_PREFIX_4 "cdr_odbc: Error
> SQLConnect %d\n", ODBC_res);
>                 SQLGetDiagRec(SQL_HANDLE_DBC, ODBC_con, 1, ODBC_stat,
> &ODBC_err, ODBC_msg, 100, &ODBC_mlen);
> >>              if(option_verbose > 10)
> >>                      ast_verbose( VERBOSE_PREFIX_4 "cdr_odbc: Error
> Details: %s\n", ODBC_msg);
>                 SQLFreeHandle(SQL_HANDLE_ENV, ODBC_env);
>                 connected = 0;
>                 return -1;
>         }
> 
> Lines marked with >> are lines I added. Here are the error messages I
> get on the console:
> 
> asterisk*CLI> load cdr_odbc.so
>  Loaded /usr/lib/asterisk/modules/cdr_odbc.so => (ODBC CDR Backend)
>   == Parsing '/etc/asterisk/cdr_odbc.conf':   == Parsing
> '/etc/asterisk/cdr_odbc.conf': Found
> 2004-05-26 18:13:54 NOTICE[6151]: cdr_odbc.c:336 odbc_load_module:
> cdr_odbc: Logging uniqueid
>        > cdr_odbc: dsn is AsteriskCDR
>        > cdr_odbc: username is asteriskcdr
>        > cdr_odbc: password is [secret]
>        > cdr_odbc: Error SQLConnect -1
>        > cdr_odbc: Error Details: [MySQL][ODBC 3.51 
> Driver]Can't connect
> to local MySQL server through socket '/tmp/mysql.sock' (2)
> 2004-05-26 18:13:54 ERROR[6151]: cdr_odbc.c:363 odbc_load_module:
> cdr_odbc: Unable to connect to datasource: AsteriskCDR
>        > cdr_odbc: Unable to connect to datasource: AsteriskCDR
> 
> So, the problem I am having is that the mysql odbc driver 
> seems to want
> to use a local socket, but I am not running mysql locally on the
> asterisk machine. I want it to connect to a remote host.
> 
> I don't see anything in the source that indicates it 
> can/should be able
> to do this. Can someone either tell me it isn't possible, or I need to
> hack the source, or it is already there and I am just blind...
> 
> Thanks,
> Adam
> 
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
> 
> 




More information about the asterisk-dev mailing list