[asterisk-users] Deadlock of asterisk on app_system

Atis Lezdins atis at iq-labs.net
Fri Jan 11 11:50:43 CST 2008


Hi,

I just had my production box deadlocked - no calls could go trough,
CLI didn't load. Last lines in log were:

[Jan 11 09:15:43] VERBOSE[7265] logger.c:     -- Executing
[28901 at local_dial:40] GotoIf("SIP/204.11.200.152-c0070ed0", "1?41:57")
in new stack
[Jan 11 09:15:43] VERBOSE[7265] logger.c:     -- Goto (local_dial,28901,41)
[Jan 11 09:15:43] VERBOSE[7265] logger.c:     -- Executing
[28901 at local_dial:41] System("SIP/204.11.200.152-c0070ed0", "sudo -u
apache echo `date` 120007172
[Jan 11 09:23:47] VERBOSE[8467] logger.c: Asterisk Event Logger
Started /var/log/asterisk/event_log

So, from this i suppose that System() command issued some kind of
deadlock. I killed asterisk with -5 to get core, and backtrace shows:

Thread 3 (process 7265):^
#0  0x00000036fb2da628 in __lll_mutex_lock_wait () from /lib64/libc.so.6^
No symbol table info available.^
#1  0x00000036fb26c641 in _L_lock_2271 () from /lib64/libc.so.6^
No symbol table info available.^
#2  0x00000036fb26ba3f in __GI__IO_list_lock () from /lib64/libc.so.6^
No symbol table info available.^
#3  0x00000036fb2955d3 in fork () from /lib64/libc.so.6^
No symbol table info available.^
#4  0x000000000042727b in ast_safe_system (s=0x41a3c9f0 "sudo -u
apache echo `date` 1200071726.3163 SIP/204.11.200.152-c0070ed0
8505755211 28901 0 >> /var/l
  pid = 0^
  x = -1073476672^
  res = 10922^
  rusage = {ru_utime = {tv_sec = 1101244208, tv_usec = 1101244640},
ru_stime = {tv_sec = 1101244224, tv_usec = 5241072}, ru_maxrss =
469252700480, ru_ixrss
  status = 0^
  __PRETTY_FUNCTION__ = "ast_safe_system"^
...

Seems that asterisk got locked on fork() and that's quite strange.
Other threads shouldn't have any effect of it. Any ideas what might
have happened?

Regards,
Atis

-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
atis at iq-labs.net
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835



More information about the asterisk-users mailing list