[Asterisk-Users] chan_local segfault
Karl Putland
karl at putland.linux-site.net
Mon Apr 7 22:19:52 MST 2003
Happened twice. There might also be a race condition and some bad
pointers in chan_local.locals_show.
First the segfault.
CLI> show locals
<unowned> -- 6001 at default
Segmentation fault (core dumped)
[root at mars asterisk]# ll -tr
total 22260
[...]
Loaded symbols for /usr/lib/asterisk/modules/chan_local.so
#0 __pthread_mutex_lock (mutex=0x5d8) at mutex.c:99
99 mutex.c: No such file or directory.
in mutex.c
(gdb) bt
#0 __pthread_mutex_lock (mutex=0x5d8) at mutex.c:99
#1 0x4161ed29 in locals_show (fd=1, argc=2, argv=0xbffff770) at chan_local.c:358
#2 0x08067268 in ast_cli_command (fd=1, s=0x80be7c8 "show locals") at cli.c:911
#3 0x080777ab in consolehandler (s=0x80be7c8 "show locals") at asterisk.c:475
#4 0x080792ed in main (argc=2, argv=0xbffffc74) at asterisk.c:1335
#5 0x400c8336 in __libc_start_main (main=0x8078900 <main>, argc=2, ubp_av=0xbffffc74, init=0x804ff8c <_init>, fini=0x8099e50 <_fini>, rtld_fini=0x4000d2fc <_dl_fini>,
stack_end=0xbffffc6c) at ../sysdeps/generic/libc-start.c:129
(gdb)
Now for something completely different.
*CLI> show locals
Local/6001 at default-1 -- 6001 at default
<unowned> -- __se at s 2
*CLI> show locals
Local/6001 at default-1 -- 6001 at default
<unowned> -- __se at s 2
-- Nobody picked up in 20000 ms
-- Hungup 'IAX[peracles]/4'
-- Executing VoiceMail("Local/6001 at default-1", "u1234") in new stack
== Parsing '/etc/asterisk/voicemail.conf': Found
-- Playing 'vm/1234/unavail'
-- Playing 'vm-intro'
-- Playing 'beep'
-- Recording to /var/spool/asterisk/vm/1234/INBOX/msg0012
WARNING[21525]: File app_voicemail.c, Line 631 (leave_voicemail): No
audio available on Local/6001 at default-1??
-- User hung up
== Parsing '/etc/asterisk/voicemail.conf': Found
== Spawn extension (macro-stdexten, s, 2) exited non-zero on
'Local/6001 at default-1' in macro 'stdexten'
== Spawn extension (default, 1999, 1) exited non-zero on
'Local/6001 at default-1'
-- User disconnected when they almost made it
== Spawn extension (default, 6001, 2) exited non-zero on
'Local/6001 at default-2'
show locals
<unowned> -- 6001 at default
UåWVSì|ÇE -- @s 2
Segmentation fault (core dumped)
This segfault Produced same traceback as above
The above results were produced by
extenstion.conf
exten => 1998,1,Macro(stdexten,1234,IAX/kputland)
exten => 1999,1,Macro(stdexten,1234,IAX/peracles)
exten => 6001,1,Answer
exten => 6001,2,Queue(dialer)
Executing this command on the manager port.
Action: Originate
Exten: 1999
Channel: Local/6001
Then running
show locals
over and over and over again rather quickly.
--
Karl Putland <karl at putland.linux-site.net>
More information about the asterisk-users
mailing list