Asterisk in background always running

Hi ,

In the morning everything was well. i was able to land call in asterisk
listen IVR, and queue the call .
And was trying to dump queue_log in mysql so what happen next
(all of a sudden i realize)
i know i cannot restart asterisk with command
asterisk -vvvvvvvgc
says asterisk already running on /var/run/asterisk.ctl use asterisk - r to connect
so i connect with
asterisk -r command

but than i see call actually not landing on asterisk . In cli not taking
core stop now command not even like sip show peers.

So i thought let stop process in back using
killall -9 safe_asterisk(it results no process killed)
killall -9 asterisk

To make it work as usual i went for installing asterisk again
installed successfully but with same problem exist.

I cannot see call flow in cli and call does not land in asterisk and no sip peers
try to register with asterisk.

What is wrong with the system can someone tell?
asterisk version is 1.6.2.4

I restart the server but with no positive result.

thank you in advance.

Mushfiq

This looks like you may have a deadlock, but there really isn’t enough to go on. If it is a deadlock, you will need to rebuild with lock debugging enabled, so that you can use “core show locks”.

Note that you should only ever use kill -9 as a last resort, and that safe_asterisk is a shell script, so killall will not find it by that name.

If this is a CentOS or RedHat like system, you should start by trying “service asterisk stop”. If that fails, you can try kill -15 on asterisk, which should cause a normal termination and also stop safe_asterisk. Only then consider using kill -9, and then stop asterisk with one of the other methods. If this still doesn’t work, you need to find the process numbers and kill everything together. In my experience you only need to go beyond service asterisk stop if you have done something silly with “service” or safe_asterisk.

You are in right track.
ps aux | grep asterisk
root 2412 0.0 0.0 12320 2228 ? Sl Mar02 0;00 asterisk -vvvvvvgc
root 17505 0.0 0.0 4200 680 pts/1 R+ 01:36 grep asterisk

so i killed 2412 precessid

kill 2412

than again asterisk -r now it says whether asterisk.ctl is exist
so in back it killed now asterisk -vvvvvvvvgc

it hanged again no call landing on asterisk, taking no command like core stop now
same problem exist

Plz you are close let me know the solution

Thanks

One thing need to mention

asterisk : /usr/lib/libxml2.so.2: no version information available (required by asterisk)

whenever i start asterisk this comes first
do i have to install libxml2?

I did but that did not help too

I’m a bit confused by that message. it looks like an installer error rather than a startup error, although I could be wrong.

Which libraries you need depend on the exact options chosen when you build Asterisk. You can use ldd to find out which libraries are needed by each program. You need to run it against each module, as well as against /usr/sbin/asterisk.

If startup is failing to complete you should look at the logs, typically in /var/log/asterisk.

I check the /var/log/asterisk/messages there is no log after 28th february when exactly this problem started.

I do not know whether it is installation problem or not because everything was working fine.

and i was working on asterisk database to have queue_log.

To see current libraries build in asterisk

ldd /usr/sbin/asterisk

/usr/sbin/asterisk: /usr/lib/libxml2.so.2: no version information available (required by /usr/sbin/asterisk)
/usr/sbin/asterisk: /usr/lib/libxml2.so.2: no version information available (required by /usr/sbin/asterisk)
linux-gate.so.1 => (0x00b62000)
libssl.so.8 => /usr/lib/libssl.so.8 (0x0220b000)
libcrypto.so.8 => /usr/lib/libcrypto.so.8 (0x0209e000)
libc.so.6 => /lib/libc.so.6 (0x00110000)
libxml2.so.2 => /usr/lib/libxml2.so.2 (0x07d0d000)
libz.so.1 => /lib/libz.so.1 (0x00282000)
libm.so.6 => /lib/libm.so.6 (0x00cc3000)
libdl.so.2 => /lib/libdl.so.2 (0x00ced000)
libpthread.so.0 => /lib/libpthread.so.0 (0x00cf4000)
libtinfo.so.5 => /lib/libtinfo.so.5 (0x008d9000)
libresolv.so.2 => /lib/libresolv.so.2 (0x07efc000)
libgssapi_krb5.so.2 => /usr/lib/libgssapi_krb5.so.2 (0x07f17000)
libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x02000000)
libcom_err.so.2 => /lib/libcom_err.so.2 (0x00b15000)
libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x07f44000)
/lib/ld-linux.so.2 (0x00b2b000)
libkrb5support.so.0 => /usr/lib/libkrb5support.so.0 (0x07e50000)
libkeyutils.so.1 => /lib/libkeyutils.so.1 (0x00b20000)
libselinux.so.1 => /lib/libselinux.so.1 (0x00295000)

what these means i got no idea may be i am wrong with command too for seeing the library to build for asterisk.

Plz let me know how will i find the libraries of asterisk is already runniing.

Mushfiq

Even though it is complaining, it seems to have found the libraries, so it possibly means that it is unable to verify the correct version is being used.

Sorry i was busy with some other work and start working this issue again now.
Ok let me tell this way i can kill asterisk running in background so the headline
asterisk in background always running should be change .

But the main problem still exist .
call does not land on asterisk .
If command to asterisk with asterisk -vvvvvvgc
it stuck in the middle and no call landing

it stuck after this message
asterisk event logger started /var/log/asterisk/event_log

and there is no loading of module and no cli>
so no call landing .

Installed freshly no result.

Please do not stop sending help regarding his issue

I have this same problem with Asterisk 1.10 beta 1 (asterisk 10), after some time or few core stop now and asterisk vvvvc commands, it stops responding to them. It says it’s working in background but not accepting any SIP calls.

Only a fresh install is working but i can’t do that 10 times a day :unamused:

Has anyone found a reason why this is happening?

A fresh install make no sense as a recovery mechanism from deadlocks. It will not achieve any more than a reboot would, and, with some Linux knowledge, you shouldn’t even need a reboot.

If you have problems on a beta version, you should really be reporting properly documented bug reports on the issue tracker. If you google for “asterisk wiki backtrace”, and then navigate around, you will get the debugging information needed for different sorts of bug reports. One of the main purposes of beta versions is to get such reports. They shouldn’t really be used by people unless they are able to provide them.

Thanks for reply, i made files for backtracing deadlocks, but for now everything is working fine, all i did is on menuselect unchecked all additional apps and other thing i installed (basically now I’m on default configuration now), and everything is working good for now :smile: