[asterisk-bugs] [JIRA] (ASTERISK-24512) asterisk -rx "module reload" + flag DEBUG_THREADS causes a deadlock

Mikael Fredin (JIRA) noreply at issues.asterisk.org
Mon Nov 10 10:26:31 CST 2014


     [ https://issues.asterisk.org/jira/browse/ASTERISK-24512?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mikael Fredin updated ASTERISK-24512:
-------------------------------------

    Description: 
When using "DEBUG THREADS" in compiler flags, to be able to provide information for a deadlock issue, the asterisk -rx "module reload" command stops working after a while with the message:
VERBOSE[34579] loader.c: The previous reload command didn't finish yet

And only a shutdown of asterisk seems to fix it.

I am using res_config_mysql for realtime configuration as well, with 50000 rows or so, if that matters. Without the debugging it's very quick to load , and I cannot reproduce the error. With the debugging it takes a lot longer plus it takes just 5-10 reloads to reproduce the issue above.


A weird thing happens when I issue the command:
gdb -ex "thread apply all bt" --batch /usr/sbin/asterisk `pidof asterisk` > /tmp/backtrace-threads.txt

...the thread(s) seem to come alive again and I can use "module reload" a few more times until it locks.

  was:
When using "DEBUG THREADS" in compiler flags, to be able to provide information for a deadlock issue, the asterisk -rx "module reload" command stops working after a while with the message:
VERBOSE[34579] loader.c: The previous reload command didn't finish yet

And only a shutdown of asterisk seems to fix it.

I am using res_config_mysql for realtime configuration as well, with 50000 rows or so, if that matters. Without the debugging it's very quick to load , and I cannot reproduce the error. With the debugging it takes a lot longer plus it takes just 5-10 reloads to reproduce the issue above.


A weird thing happens when I issue the command:
gdb -ex "thread apply all bt" --batch /usr/sbin/asterisk `pidof asterisk` > /tmp/backtrace-threads.txt

...the lock seems to go away after I issue it.


> asterisk -rx "module reload" + flag DEBUG_THREADS causes a deadlock
> -------------------------------------------------------------------
>
>                 Key: ASTERISK-24512
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-24512
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Core/Configuration
>    Affects Versions: 1.8.27.0, 1.8.31.1
>         Environment: CentOS release 6.5
>            Reporter: Mikael Fredin
>         Attachments: backtrace-threads.txt, core-show-locks.txt
>
>
> When using "DEBUG THREADS" in compiler flags, to be able to provide information for a deadlock issue, the asterisk -rx "module reload" command stops working after a while with the message:
> VERBOSE[34579] loader.c: The previous reload command didn't finish yet
> And only a shutdown of asterisk seems to fix it.
> I am using res_config_mysql for realtime configuration as well, with 50000 rows or so, if that matters. Without the debugging it's very quick to load , and I cannot reproduce the error. With the debugging it takes a lot longer plus it takes just 5-10 reloads to reproduce the issue above.
> A weird thing happens when I issue the command:
> gdb -ex "thread apply all bt" --batch /usr/sbin/asterisk `pidof asterisk` > /tmp/backtrace-threads.txt
> ...the thread(s) seem to come alive again and I can use "module reload" a few more times until it locks.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list