Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected service closeing #117

Open
gonsalez-ru opened this issue Sep 18, 2020 · 5 comments
Open

Unexpected service closeing #117

gonsalez-ru opened this issue Sep 18, 2020 · 5 comments

Comments

@gonsalez-ru
Copy link

gonsalez-ru commented Sep 18, 2020

After executed in dialplan DongleSendSMS application Asterisk shuting down:

 [messages]
 exten => _X.,1,NoOp("${EXTEN} ${MESSAGE(body)}")
 exten => _X.,n,DongleSendSMS(gsm1,${EXTEN},"${MESSAGE(body)}")
 exten => h,n,Hangup()
Asterisk Ready.
    -- Executing [+79161234567@messages:1] NoOp("Message/ast_msg_queue", ""+79161234567 456"") in new stack
    -- Executing [+79161234567@messages:2] DongleSendSMS("Message/ast_msg_queue", "gsm1,+79161234567,"456"") in new stack
gate*CLI>
Disconnected from Asterisk server
Asterisk cleanly ending (0).
Executing last minute cleanups
Asterisk ending (0). 

P.S.
CLI "dongle sms" command works fine

@gonsalez-ru
Copy link
Author

I need your advise. What diagnostic actions can i do to gather additional debug information?

@wdoekes
Copy link
Owner

wdoekes commented Sep 19, 2020

Start the asterisk daemon from gdb:

# gdb `which asterisk`
(gdb) run asterisk -c

And then do the dongle stuff.

Then when it crashes, do:

bt
bt full

That should show you some info.

@gonsalez-ru
Copy link
Author

gonsalez-ru commented Sep 19, 2020

Since i use precompiled for mipsel router chan_dongle module i'm limited in debugging toools. I didn't find GDB packet for my platform and I'm not familar with exotic cross compilation. :-(

@wdoekes
Copy link
Owner

wdoekes commented Sep 19, 2020

Perhaps dmesg tells you at least an address (ip instruction pointer). Which you might be able to look up through addr2line. You may need to do some hexadecimal math to get the right value.

@gonsalez-ru
Copy link
Author

Here is dmesg out:
do_page_fault(): sending SIGSEGV to asterisk for invalid read access from 00000000
epc = 76b34540 in libc-2.27.so[76aad000+17a000]
ra = 756eb6f0 in chan_dongle.so[756e8000+3c000]

There are two packets installed with libc:
opkg files libc | grep libc-2.27.so
/opt/lib/libc-2.27.so

opkg files gcc | grep libc-2.27.so
/opt/lib/gcc/mipsel-openwrt-linux-gnu/7.4.0/libc-2.27.so

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants