bar top left
bar top right
left curve
right curve
Welcome, Guest

MPG123 CRASHES ASTERISK 1.4.28..
(1 viewing) (1) Guest
Go to bottom
Post Reply
Post New Topic
Page: 12
TOPIC: MPG123 CRASHES ASTERISK 1.4.28..
#44707
MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 0
Greetings all,

I've read all kind of posts related to mpg123 crashing Asterisk 1.4.x when you use it for a streaming music category but nothing seems to be concrete to solve the issue.

I have Elastix 1.6-13 64 bits with Asterisk 1.4.28 and the latest mpg123 1.10.0 64-bit version (just in case I am told I am using the 32-bit version under the 64-bit environment).

The program seems to crash res_musiconhold.so at random times leaving the PBX unusable until you manually have to restart the asterisk server via /etc/rc.d/init.d/asterisk restart

But it also happens under 32-bit environments, it looks like Asterisk 1.4.28 doesn't like mpg123 so question is... do you know of a true workaround for this problem or, instead, do you know of a STEADY streaming audio application that Asterisk does like to play any stream?

By the way, another problem mpg123 has is that it stops playing the music after a few days as long as it does not crash asterisk first, of course!


Thank you in advance,


Paul
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
striderec
Junior Boarder
Posts: 70
graphgraph
User Offline Click here to see the profile of this user
Gender: Male EST Telecomm, Inc. pfabrej Location: Miami, FL Birthday: 10/01
Last Edit: 2010/01/30 14:12 By striderec.
Reply Quote
 
#44716
Re:MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 0
yes we have the same problem
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
rodgerg
Junior Boarder
Posts: 64
graphgraph
User Offline Click here to see the profile of this user
Reply Quote
 
#44747
Re:MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 7
This has been a real pain in the rear end for a while

Here is what I did to fix my issue

Removed mpg123 altogether and installed madplay

Files you need are
libid3tag-0.15.1b
libmad-0.15.1b
madplay-0.15.2b

You can get them from sourceforage
Now you need to edit your musiconhold_custom.conf as follows

[wave]
mode=custom
application=/tmp/music.sh

Then create a file in /tmp/ (or wherever you want to, just update the above lines too if you don't use /tmp) called music.sh
#!/bin/bash

wget -q -T 120 -O - 216.155.137.148:8004 | /usr/local/bin/madplay -Q -o raw:- --mono -R 8000 -a -20 -

Your path to bash may differ, as well as paths to wget and madplay. Use locate or which to find them.
The obvious URL above is the station I've chosen, be sure you change it to the station you have selected.

You can create extension to test

exten => 6000,1,Answer
exten => 6000,2,SetMusicOnHold(default)
exten => 6000,3,MusicOnHold()
exten => 6000,4,HangUp

It took a little time to get this working but now don't have the previous issues
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
DaveD
Senior Boarder
Posts: 408
graphgraph
User Offline Click here to see the profile of this user
floors324@hotmail.com Location: Wollongong Australia
Reply Quote
 
#44751
Re:MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 0
Thank you very much Dave!!!

Madplay works great...... But I yet have to test it further and see if it won't crash my asterisk but so far so good..... mpg123 is indeed a pain in the ass.. I wonder if madplay does not die after a few days like mpg123 does.. you know, if the internet connection experiences a little problem, you must restart asterisk and mpg123 to have streaming audio again.. i suppose that since your script uses WGET every time it is invoked, the audio never dies..... right?

In any case thank you very much! I added a karma for you.. Ah, and by the way, I like your instrumental radio station!

- Paul
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
striderec
Junior Boarder
Posts: 70
graphgraph
User Offline Click here to see the profile of this user
Gender: Male EST Telecomm, Inc. pfabrej Location: Miami, FL Birthday: 10/01
Last Edit: 2010/01/31 22:29 By striderec.
Reply Quote
 
#44752
Re:MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 7
When the internet goes down feed stops.
But took around 5 seconds when internet was back and music started again

Have had this running for 2 weeks and no real issues so far

Also have another method with madplay that gets rid of that pesky MOH starts from beginning on all calls placed on hold and never plays next mp3 in list.
Will post a howto in next few days for that method
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
DaveD
Senior Boarder
Posts: 408
graphgraph
User Offline Click here to see the profile of this user
floors324@hotmail.com Location: Wollongong Australia
Reply Quote
 
#44768
Re:MPG123 CRASHES ASTERISK 1.4.28.. 2 Years ago Karma: 33
good job, I'm glad I'm not the only one who had problem with mpg123. I played with it two months ago and never achieved to have a stable solution. I was putting that on all the mods and tries I've done on my server. I will try your fix later this week.

thanks
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
Patrick_elx
Gold Boarder
Posts: 1112
graphgraph
User Offline Click here to see the profile of this user
Gender: Male Location: Florida, USA
Reply Quote
 
#46606
Re:MPG123 CRASHES ASTERISK 1.4.28.. 1 Year, 11 Months ago Karma: 7
Well gents,

I went and did the streaming thingeeee also (all I wanted was to listen to Smooth Jazz) and it took down server as stated in previous post. Go figure, I read it in EWT, thought that would be cool thing to do,followed directions as stated and it crashes.

I assume that since I didn't see any fixes it still a major prob in the backside??? What is the best way to remove the MP-3 stuff? Is it in a seperate directory or is there 300 individual files I have to hunt for.

I guess before I make any more changes to this machine I should research the forum first, although I can't really complain, as it's been working for several months now without a glitch. I need to correct the short I have between the chair and the desk I guess.

Also did the portion get completed for the continuous, next in line play as mentioned? Is so where may I find that post?

Thanks Guys
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
Amphibian
At my age, I don't have time to read the book.....
Senior Boarder
Posts: 261
graphgraph
User Offline Click here to see the profile of this user
Gender: Male monster_cookie21482 Amphibian Solutions monster_cookie2148 Location: Texas my friend, Texas Birthday: 01/01
"I may not be the sharpest tool in the shed, but, I'm not the only dull tool in the shed either.
Reply Quote
 
#46610
Re:MPG123 CRASHES ASTERISK 1.4.28.. 1 Year, 11 Months ago Karma: 7
Sorry I have not completed the next in line play, will try to get it done in next few days for you
But you will still need to install madplay.

The way I installed was to use webmin and search rpmfind for madplay
yum -y install webmin
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
DaveD
Senior Boarder
Posts: 408
graphgraph
User Offline Click here to see the profile of this user
floors324@hotmail.com Location: Wollongong Australia
Last Edit: 2010/02/27 03:45 By DaveD.Reason: spelling
Reply Quote
 
#49202
Re:MPG123 CRASHES ASTERISK 1.4.28.. 1 Year, 10 Months ago Karma: 7
Happy to report in Elastix 2.0 so far MPG123 does not crash in the 64bit version and streaming works fine.This is with 4 different streams for different inbounds

Have run this for 1 week solid so far in production to see if I could crash it.
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
DaveD
Senior Boarder
Posts: 408
graphgraph
User Offline Click here to see the profile of this user
floors324@hotmail.com Location: Wollongong Australia
Reply Quote
 
#58471
Re:MPG123 CRASHES ASTERISK 1.4.28.. 1 Year, 5 Months ago Karma: 0
I followed the instructions to setup using madplay. It worked at first using your sample stream, so I went to change it to a diffrent stream. Now it wont stop playing that stupid robot file. I changed everything back and still the same thing. I checked the permissions on the music.sh file and asterisk has full control

Any Ideas?

Thanks

David
Enter code here   
Please note: although no board code and smiley buttons are shown, they are still usable.
lazergeek
Fresh Boarder
Posts: 2
graphgraph
User Offline Click here to see the profile of this user
Reply Quote
 
Go to top
Post Reply
Post New Topic
Page: 12
Moderators: Bob, jgutierrez