[OpenSIPS-Users] opensips crash with location data

Pasan Meemaduma pasandev at ymail.com
Fri Jun 6 05:18:22 CEST 2014


Hi Bogdan,

Thanks for the reply. I created the table using normal schema it looks fine to me. I was refering to the old url you gave me. There in that table attr was missing :)


this is the url missing attr in location table
http://www.opensips.org/Documentation/Install-DBSchema-1-10#AEN7254  


below is my table schema,

mysql> desc location;
+---------------+------------------+------+-----+---------------------+----------------+
| Field         | Type             | Null | Key | Default             | Extra          |
+---------------+------------------+------+-----+---------------------+----------------+
| id            | int(10) unsigned | NO   | PRI | NULL                | auto_increment |
| username      | char(64)         | NO   | MUL |                     |                |
| domain        | char(64)         | YES  |     | NULL                |                |
| contact       | char(255)        | NO   |     |                     |                |
| received      | char(128)        | YES  |     | NULL                |                |
| path          | char(128)        | YES  |     | NULL                |                |
| expires       | datetime         | NO   |     | 2020-05-28 21:32:15 |                |
| q             | float(10,2)      | NO   |     | 1.00                |                |
| callid        | char(255)        | NO   |     | Default-Call-ID     |                |
| cseq          | int(11)          | NO   |     | 13                  |                |
| last_modified | datetime         | NO   |     | 1900-01-01 00:00:01 |                |
| flags         | int(11)          | NO   |     | 0                   |                |
| cflags        | int(11)          | NO   |     | 0                   |                |
| user_agent    | char(255)        | NO   |     |                     |                |
| socket        | char(64)         | YES  |     | NULL                |                |
| methods       | int(11)          | YES  |     | NULL                |                |
| sip_instance  | char(255)        | YES  |     | NULL                |                |
| attr          | char(255)        | YES  |     | NULL                |                |
+---------------+------------------+------+-----+---------------------+----------------+


attr holds NULL values for all entries.

do I have to run below in gdb after running bt full right ?

this is what i got

(gdb) f 1
#1  0x00007f64823a60a2 in dbrow2info (contact=0x7fffe0246180, vals=0x7f648287a260) at udomain.c:306
306    in udomain.c
(gdb) p (vals+6)->val.string_val
$2 = 0x0
(gdb) 


-----------------without running bt full ------------- just in case :)
(gdb) f 1
#1  0x00007f64823a60a2 in dbrow2info (contact=0x7fffe0246180, vals=0x7f648287a260) at udomain.c:306
306    udomain.c: No such file or directory.
(gdb) p (vals+6)->val.string_val
$1 = 0x0




On Thursday, 5 June 2014, 17:07, Bogdan-Andrei Iancu <bogdan at opensips.org> wrote:
 


Thanks for the backtrace. In DB, what do you have for the "attr" value ? NULL or an empty string ?

In gdb, could you do:
    f 1
    p (vals+6)->val.string_val

Thanks,

Bogdan-Andrei Iancu
OpenSIPS Founder and Developer http://www.opensips-solutions.com
On 05.06.2014 06:15, Pasan Meemaduma wrote:

oops sorry I forgot opensips-dbg :) bt reattached.
>
>
>I have change some sensitive values with 'x' as below, hope it wont affect u r investigations
>
>
>        contact = {s = 0xf91eab "sip:xxxxxxxxxx at xxx.xxx.xxx.xx", len = 29}
>
>
>
>
>On Thursday, 5 June 2014, 8:34, Pasan Meemaduma <pasandev at ymail.com> wrote:
> 
>
>
>Hi Bogdan,
>
>
>I double checked the schema and it is correct. btw doc needs fixing its missing attr column which is needed by 1.10 for location table otherwise I'll get below error.
>
>
>Jun  5 12:57:26  x/usr/sbin/opensips[30176]: CRITICAL:db_mysql:wrapper_single_mysql_real_query: driver error (1054): Unknown column 'attr' in 'field list'
>Jun  5 12:57:26 x /usr/sbin/opensips[30177]:
                        DBG:core:db_do_init: connection 0x7f4dc04c1c28
                        inserted in pool as 0x7f4dc04c1d30
>Jun  5 12:57:26 x /usr/sbin/opensips[30176]:
                        ERROR:core:db_do_query: error while submitting
                        query - [select
                        username,contact,expires,q,callid,cseq,flags,cflags,user_agent,received,path,socket,methods,last_modified,sip_instance,attr
                        from location ]
>Jun  5 12:57:26 anacardium3backup
                        /usr/sbin/opensips[30176]:
                        ERROR:usrloc:preload_udomain: db_query (1)
                        failed
>
>
>:)
>
>
>
>I got the backtrace as you requested , It doesn't seems right to me.  does it make any sense ? or did I miss something getting it ?
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20140605/6d6336fa/attachment-0001.htm>


More information about the Users mailing list