i noticed that sr master version crashes at startup if a listening address does not exist:
May 3 10:19:43 sip /usr/sbin/sip-proxy[27907]: ERROR: <core> [udp_server.c:400]: ERROR: udp_init: bind(8, 0xb7210490, 16) on 192.98.102.10: Cannot assign requested address May 3 10:19:43 sip kernel: [189745.416438] sip-proxy[27907]: segfault at 786e6570 ip b767ce38 sp bf85f67c error 4 in libc-2.11.2.so[b760a000+140000] May 3 10:19:43 sip sip-proxy: ERROR: <core> [daemonize.c:307]: Main process exited before writing to pipe
-- juha
On May 03, 2011 at 10:23, Juha Heinanen jh@tutpro.com wrote:
i noticed that sr master version crashes at startup if a listening address does not exist:
May 3 10:19:43 sip /usr/sbin/sip-proxy[27907]: ERROR: <core> [udp_server.c:400]: ERROR: udp_init: bind(8, 0xb7210490, 16) on 192.98.102.10: Cannot assign requested address May 3 10:19:43 sip kernel: [189745.416438] sip-proxy[27907]: segfault at 786e6570 ip b767ce38 sp bf85f67c error 4 in libc-2.11.2.so[b760a000+140000] May 3 10:19:43 sip sip-proxy: ERROR: <core> [daemonize.c:307]: Main process exited before writing to pipe
I cannot reproduce it. Tried it with the current master (a8859f) and a very basic config:
$ ./ser -Ef stateless.cfg -l 1.2.3.4 0(12034) WARNING: <core> [socket_info.c:912]: WARNING: fix_hostname: could not rev. resolve 1.2.3.4 0(12034) WARNING: <core> [socket_info.c:912]: WARNING: fix_hostname: could not rev. resolve 1.2.3.4 Listening on udp: 1.2.3.4:5060 tcp: 1.2.3.4:5060 Aliases: *: foo.bar:* *: iptel.org:*
0(12036) ERROR: <core> [udp_server.c:400]: ERROR: udp_init: bind(3, 0xb72221a4, 16) on 1.2.3.4: Cannot assign requested address
Do you get a coredump? If so, could you send a backtrace?
Andrei
Andrei Pelinescu-Onciul writes:
I cannot reproduce it.
i tried again and got the same crash:
May 5 22:39:28 sip /usr/sbin/sip-proxy[6876]: ERROR: <core> [udp_server.c:400]: ERROR: udp_init: bind(8, 0xb7275490, 16) on 192.98.102.10: Cannot assign requested address May 5 22:39:28 sip kernel: [ 7700.781318] sip-proxy[6876]: segfault at 786e6570 ip b76e1e38 sp bfaa7ecc error 4 in libc-2.11.2.so[b766f000+140000] May 5 22:39:29 sip sip-proxy: ERROR: <core> [daemonize.c:307]: Main process exited before writing to pipe
Do you get a coredump? If so, could you send a backtrace?
here you go:
(gdb) bt #0 0xb76e1e38 in strcmp () from /lib/i686/cmov/libc.so.6 #1 0x080f19f9 in find_mod_export_record (mod=0xb747d080 "db_mysql", name=0xb7241963 "db_bind_api", param_no=0, flags=0, mod_if_ver=0xbfaa7f5c) at sr_module.c:615 #2 0x080f1c56 in find_mod_export (mod=0xb747d080 "db_mysql", name=0xb7241963 "db_bind_api", param_no=0, flags=0) at sr_module.c:680 #3 0xb723925c in db_bind_mod (mod=0xb66a75a4, mydbf=0x8) at db.c:199 #4 0xb66a3fe2 in ht_db_init_con () at ht_db.c:74 #5 0xb669be84 in destroy () at htable.c:218 #6 0x080efb84 in destroy_modules () at sr_module.c:732 #7 0x0809000c in cleanup (show_status=0) at main.c:530 #8 0x08090c99 in shutdown_children (show_status=0, sig=<value optimized out>) at main.c:672 #9 0x080937c7 in main (argc=17, argv=0xbfaa8224) at main.c:2452
-- juha