Asterisk died with code 1.

procha

New Member
Joined
Jul 23, 2008
Messages
4
Reaction score
0
Hi, I get the following messages on a fresh install every time I perform an "amportal restart"

mpg123: no process killed
Asterisk ended with exit status 1
Asterisk died with code 1.
cat: /var/run/asterisk.pid: No such file or directory
Automatically restarting Asterisk.
mpg123: no process killed
Asterisk ended with exit status 1
Asterisk died with code 1.
cat: /var/run/asterisk.pid: No such file or directory
Automatically restarting Asterisk.
mpg123: no process killed
Asterisk ended with exit status 1
Asterisk died with code 1.
cat: /var/run/asterisk.pid: No such file or directory
Automatically restarting Asterisk.


I have to do killall -9 safe_asterisk and killall -9 asterisk, in order to stop the above messages from cycling.

Any ideas?
 

rapidnet

New Member
Joined
Jul 22, 2008
Messages
64
Reaction score
0
Ok, I have the same problem, here is status

Status Version 1.2.5 released on Date 072508
aster.rapid.net on 192.168.6.250
********************************************************************
* PBX in a Flash Version 1.2 Daemon Status *
* Running Asterisk 1.4 *
********************************************************************
* Asterisk * ONLINE * Zaptel * ONLINE * MySQL * ONLINE *
* SSH * ONLINE * Apache * ONLINE * Iptables * ONLINE *
* Fail2ban * ONLINE * Ethernet0 * ONLINE * IP Connect * ONLINE *
* BlueTooth * ONLINE * Hidd * ONLINE * NTPD * ONLINE *
* Sendmail * ONLINE * Samba * OFFLINE * Webmin * ONLINE *
********************************************************************
* Running Asterisk Version : Asterisk 1.4.21.2
* Asterisk Source Version : 1.4.21.2
* Zaptel Source Version : 1.4.11
* Libpri Source Version : 1.4.6
* Addons Source Version : 1.4.7
********************************************************************
CentOS release 5 (Final) - 64 Bit ** Kernel: 2.6.18-53.1.13.el5
root@pbx:/etc/asterisk $

What I noticed is when using amportal restart..

the path to asterisk.pid SHOULD be

/var/run/asterisk/asterisk.pid

BUT the cat command is looking for it at

/var/run/asterisk.pid


I was just looking for the fix, or the script that is being run to fix it..


BTW, the setting in /etc/asterisk/asterisk.conf

is

astrundir => /var/run/asterisk


Does this help?
 

rapidnet

New Member
Joined
Jul 22, 2008
Messages
64
Reaction score
0
Ok, I think I found the issue,please see :

/usr/sbin/safe_asterisk

line 13 reads

ASTPIDFILE=/var/run/asterisk.pid

should be :

ASTPIDFILE=/var/run/asterisk/asterisk.pid



BUT

This doesn't really fix it for me..


I seem to get safe_asterisk and asterisk both running at the same time....


Not sure why....
 

darmock

PIAF Developer
Joined
Oct 18, 2007
Messages
2,892
Reaction score
98
This is a well known problem with no easy permanent solution. This only occurs on 64bit machines. The simple interim fix it to run update-scripts and then update-fixes.

Update-fixes will detect that you have a 64bit system and advise you that you must recompile some things. You must choose yes to this question. After update-fixes is done you will find amportal restart on 64bit works again.

Sorry I can't be more helpful.

Tom
 

rapidnet

New Member
Joined
Jul 22, 2008
Messages
64
Reaction score
0
That is what I thought, but I have done an update-scripts, then update-fixes, reboot..

When I

ps -aux|grep asterisk

I see :


root 2472 0.0 0.0 65880 676 ? S 23:40 0:00 /bin/sh /usr/sbin/safe_asterisk -U asterisk -G asterisk
asterisk 2483 0.9 1.1 389784 11772 ? Sl 23:40 0:00 /usr/sbin/asterisk -f -U asterisk -G asterisk -vvvg -c


I shouldn't see both safe_asterisk and asterisk running at same time after a reboot, right?
 

jroper

Guru
Joined
Oct 20, 2007
Messages
3,832
Reaction score
71
Hi

When it fails, what iis the result of tail /var/log/asterisk/full

Joe
 

rapidnet

New Member
Joined
Jul 22, 2008
Messages
64
Reaction score
0
cccRight now since fixing the script for the path to asterisk.pid....

I don't get a failure...

I just get safe_asterisk and asterisk both running concurrently...whenever I reboot...
Same if I

killall -9 safe_asterisk
killall -9 asterisk
amportal start


If I ps -aux| grep asterisk

I have safe_asterisk, and asterisk both running.


Here is the output though

root@pbx:/var/log/asterisk $ tail full
[Aug 9 10:34:28] VERBOSE[5386] logger.c: == Registered format 'jpg' (JPEG (Joint Picture Experts Group))
[Aug 9 10:34:28] VERBOSE[5386] logger.c: format_jpeg.so => (JPEG (Joint Picture Experts Group) Image Format)
[Aug 9 10:34:28] VERBOSE[5386] logger.c: == Parsing '/etc/asterisk/festival.conf': [Aug 9 10:34:28] VERBOSE[5386] logger.c: Found
[Aug 9 10:34:28] VERBOSE[5386] logger.c: == Registered application 'Festival'
[Aug 9 10:34:28] VERBOSE[5386] logger.c: app_festival.so => (Simple Festival Interface)
[Aug 9 10:34:28] VERBOSE[5386] logger.c: Asterisk Ready.
[Aug 9 10:34:34] VERBOSE[5460] logger.c: == Parsing '/etc/asterisk/manager.conf': [Aug 9 10:34:34] VERBOSE[5460] logger.c: Found
[Aug 9 10:34:34] VERBOSE[5460] logger.c: == Parsing '/etc/asterisk/manager_additional.conf': [Aug 9 10:34:34] VERBOSE[5460] logger.c: Found
[Aug 9 10:34:34] VERBOSE[5460] logger.c: == Parsing '/etc/asterisk/manager_custom.conf': [Aug 9 10:34:34] VERBOSE[5460] logger.c: Found
[Aug 9 10:34:34] VERBOSE[5460] logger.c: == Manager 'admin' logged on from 127.0.0.1
root@pbx:/var/log/asterisk $cxcxcxcxxcx


With this issue, I don't think it matters, but...

this is running under VMware ESXi 3.5 Update 2

Has single core assigned, (2.4 Ghz AMD Opteron 275) 1 gig of ram, and 10 gigs of disk).

At this point it is the only Vm running....

This is a brand new install....


I did setup my initial trunks, but right now they are all disabled. I am running another server with TrixBox 1.1, and want to migrate everything..
 

rapidnet

New Member
Joined
Jul 22, 2008
Messages
64
Reaction score
0
Ok...

I think the issue is resolved for me.... I 'THOUGHT/ASSUMED' safe_asterisk and ASTERISK shouldn't run concurrently, but that assumption is wrong I think?

It is normal....So, my solution in my second post is the solution for those with the original issue....

Ok, I think I found the issue,please see :

/usr/sbin/safe_asterisk

line 13 reads

ASTPIDFILE=/var/run/asterisk.pid

should be :

ASTPIDFILE=/var/run/asterisk/asterisk.pid
 

Snapdragon

New Member
Joined
Jul 29, 2008
Messages
92
Reaction score
1
Unforunately running update-fixes and recompiling doesn't actually fix the problem. I can run amportal restart once, but twice or more causes it to crash again.

I don't have any exotic equipment, but maybe it's a SATA thing?

I tried a straight CD install, plus diong fixes, plus getting new source, plus getting yum -y, plus getting the new kernal, all with the same result.

If it will help at all I can provide logs or hardware descriptions.
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,206
Reaction score
5,228
Try once more and skip the yum update. If it still bombs, we'll turn it into a *BUG* :wink5:
 

Members online

Forum statistics

Threads
25,824
Messages
167,829
Members
19,249
Latest member
jetest
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top