Asterisk hangs up during call

Hi,

I am new to asterisk management and having a wired issue. My asterisk hangs very frequently and it stops responding. All incoming and outgoing lines become nonfunctional, and I need to do a system reboot every time to make them functional.

Here is the asterisk log at the time of restart. check log on [2018-02-05 06:38:27]

[2018-02-05 06:38:26] WARNING[6551] func_cdr.c: CDR requires a value (CDR(variable)=value)
)[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:27] GosubIf(“SIP/207-000002d9”, “0?sub-flp-2,s,1()”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:28] Set(“SIP/207-000002d9”, “OUTNUM=2092095”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:29] Set(“SIP/207-000002d9”, “custom=SIP/ETISALAT_TRUNK”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:30] ExecIf(“SIP/207-000002d9”, “0?Set(DIAL_TRUNK_OPTIONS=M(setmusic^default)T)”) in new$
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:31] ExecIf(“SIP/207-000002d9”, “0?Set(DIAL_TRUNK_OPTIONS=TM(confirm))”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:32] Macro(“SIP/207-000002d9”, “dialout-trunk-predial-hook,”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk-predial-hook:1] MacroExit(“SIP/207-000002d9”, “”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:33] GotoIf(“SIP/207-000002d9”, “0?bypass,1”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:34] ExecIf(“SIP/207-000002d9”, “1?Set(CONNECTEDLINE(num,i)=2092095)”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:35] ExecIf(“SIP/207-000002d9”, “1?Set(CONNECTEDLINE(name,i)=CID:044069683)”) in new sta$
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:36] ExecIf(“SIP/207-000002d9”, “0?Set(CONNECTEDLINE(name,i)=CID:(Hidden)044069683)”) in$
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:37] GotoIf(“SIP/207-000002d9”, “0?customtrunk”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] pbx.c: Executing [s@macro-dialout-trunk:38] Dial(“SIP/207-000002d9”, “SIP/ETISALAT_TRUNK/2092095,300,T”) in new stack
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] netsock2.c: Using SIP RTP TOS bits 184
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] netsock2.c: Using SIP RTP CoS mark 5
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] app_dial.c: Called SIP/ETISALAT_TRUNK/2092095
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] netsock2.c: Using SIP RTP CoS mark 5
[2018-02-05 06:38:26] VERBOSE[25075][C-0000016d] app_dial.c: Called SIP/ETISALAT_TRUNK/2092095
[2018-02-05 06:38:27] VERBOSE[25075][C-0000016d] app_dial.c: SIP/ETISALAT_TRUNK-000002da is making progress passing it to SIP/207-000002d9
[2018-02-05 06:38:27] VERBOSE[25075][C-0000016d] app_dial.c: SIP/ETISALAT_TRUNK-000002da is ringing
[2018-02-05 06:38:27] WARNING[25075][C-0000016d] translate.c: no samples for g722tolin16
[2018-02-05 06:39:00] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.152:57032;rinstance=7aba8bb909c517d6 is now Unreachable. RTT: 0.000 msec
[2018-02-05 06:39:00] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Endpoint 102 is now Unreachable
[2018-02-05 06:39:03] VERBOSE[6497] asterisk.c: Remote UNIX connection
[2018-02-05 06:39:03] VERBOSE[25180] asterisk.c: Waiting for inactivity to perform halt…
[2018-02-05 06:39:05] ERROR[6577] manager.c: Unable to process manager action ‘Ping’. Asterisk is shutting down.
[2018-02-05 06:39:14] VERBOSE[5308] res_pjsip_registrar.c: Added contact ‘sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3’ to AOR ‘102’ with expiration of 3600 seconds
[2018-02-05 06:39:14] VERBOSE[14906] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3 has been created
[2018-02-05 06:39:15] VERBOSE[14906] res_pjsip/pjsip_configuration.c: Endpoint 102 is now Reachable
[2018-02-05 06:39:15] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3 is now Reachable. RTT: 23.607 msec
[2018-02-05 06:39:15] VERBOSE[6980] res_pjsip_registrar.c: Removed contact ‘sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3’ from AOR ‘102’ due to request
[2018-02-05 06:39:15] VERBOSE[14906] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3 has been deleted
[2018-02-05 06:39:15] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Endpoint 102 is now Unreachable
[2018-02-05 06:39:15] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3 has been created
[2018-02-05 06:39:15] VERBOSE[9602] res_pjsip_registrar.c: Added contact ‘sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3’ to AOR ‘102’ with expiration of 3600 seconds
[2018-02-05 06:39:15] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Endpoint 102 is now Reachable
[2018-02-05 06:39:15] VERBOSE[14906] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.153:61412;rinstance=6b7c8d598ab4c1f3 is now Reachable. RTT: 32.770 msec
[2018-02-05 06:39:15] ERROR[6577] manager.c: Unable to process manager action ‘MailboxCount’. Asterisk is shutting down.
[2018-02-05 06:39:20] ERROR[6577] manager.c: Unable to process manager action ‘Ping’. Asterisk is shutting down.
[2018-02-05 06:39:24] VERBOSE[6616][C-0000016e] netsock2.c: Using SIP RTP TOS bits 184
[2018-02-05 06:39:24] VERBOSE[6616][C-0000016e] netsock2.c: Using SIP RTP CoS mark 5
[2018-02-05 06:39:24] WARNING[6616][C-0000016e] channel.c: Channel allocation failed: Refusing due to active shutdown
[2018-02-05 06:39:24] WARNING[6616][C-0000016e] chan_sip.c: Unable to allocate AST channel structure for SIP channel
[2018-02-05 06:39:24] NOTICE[6616][C-0000016e] chan_sip.c: Unable to create/find SIP channel for this INVITE

Kindly let me know how i could fix this.

regards
Mubasshar

It looks like someone requested a shutdown from the Asterisk console.

Hi David,

Thanks for the reply, that should be me as I had mentioned earlier once the asterisk becomes unresponsive, I have to restart it from the console to get it back to normal.

what about these lines.

[2018-02-05 06:38:27] VERBOSE[25075][C-0000016d] app_dial.c: SIP/ETISALAT_TRUNK-000002da is making progress passing it to SIP/207-000002d9
[2018-02-05 06:38:27] VERBOSE[25075][C-0000016d] app_dial.c: SIP/ETISALAT_TRUNK-000002da is ringing
[2018-02-05 06:38:27] WARNING[25075][C-0000016d] translate.c: no samples for g722tolin16
[2018-02-05 06:39:00] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Contact 102/sip:102@10.0.1.152:57032;rinstance=7aba8bb909c517d6 is now Unreachable. RTT: 0.000 msec
[2018-02-05 06:39:00] VERBOSE[6575] res_pjsip/pjsip_configuration.c: Endpoint 102 is now Unreachable

or is there any way I could figure out the reason for this behavior.

regards
Mubassahr

https://wiki.asterisk.org/wiki/display/AST/Getting+a+Backtrace#GettingaBacktrace-GettingInformationForADeadlock

It seems asterisk halts after every 24 hours.

Hi,

Now i got the pattern, Asterisk restarts automatically after 24 hours. Is there any way to find the script which is causing this.

Regards