Hmpf, if you are using FreePBX 2.5 or later all you have to do is to click on Music on Hold, click on Add Streaming Category, fill in the details and away you go.
You need mpg123 and the details for the stream.
Just follow the Elastixconnection article, go to the heading STREAMING MUSIC ON HOLD FOR FREEPBX 2.5 AND FURTHER
You can start by testing this string for a stream (Application in FreePBX):
Patience, the above stream takes almost 30 seconds to start.
Note 2: Don’t abuse the above link, it is my favorite radio station Gamla Godingar from Sweden. Just use it for the test.
Note 3: No, I don’t answer questions about how to obtain mpg123 if it is not available as that question have been asked and answered many many times.
I have tried this thing in Add stream no go
Tried musiconhold.conf and musiconhold_custom.conf still nothig.
Below is my musiconhold.conf file
; Music on hold class definitions
; This is using the new 1.2 config file format, and will not work with 1.0
; based Asterisk systems
; #include musiconhold_custom.conf #include musiconhold_additional.conf
[classes]
default =>quietmp3:/var/lib/asterisk/mohmp3/stream,http://scfire-mtc-aa04.strea$
[moh_files]
default => /var/lib/asterisk/mohmp3,r #include musiconhold_additional.conf
; class definition for Streaming MOH
;stream => quietmp3:/var/lib/asterisk/mohmp3/stream
; class definitions For A2Billing
acc_1 => mp3:/var/lib/asterisk/mohmp3/acc_1
acc_2 => mp3:/var/lib/asterisk/mohmp3/acc_2
acc_3 => mp3:/var/lib/asterisk/mohmp3/acc_3
This is my musiconhold_custom.conf file
;placeholder for future expansion PIAF Dev Team
[uptemposmoothjazz]
mode=custom
application = /usr/bin/mpg123 -q -s --mono -r 8000 -f 800 -b 0 http://scfire-dt$
;
; Music on hold class definitions
; This is using the new 1.2 config file format, and will not work with 1.0
; based Asterisk systems
;
#include musiconhold_custom.conf
#include musiconhold_additional.conf
When you add the streaming in FreePBX it writes out those changes to musiconhold_additional.conf
If you have followed my example above your musiconhold_additional.conf will look something like this:
I going to start from a fresh install and try it again just in case i screwed something up. But Im not the only one having trouble with this I check the forums and irc and they all have some kinda of complaint either it worked or they gave up.
I even called some of the so called paid support people who advertise online not FREEPBX support but others and they were just as lost as me.
I know this is an old thread but I found it while looking for a solution myself.
My problem was that I was trying to stream aac and not mp3. I discovered this by running mpg123 from the shell with the verbose flag (-v) as suggested above.
I had my previous post unanswered while trying to make streaming mode the default MoH class
So I found your post stating it is not possible: is this the final answer ?
Is that why I can find lot of people asking for this feature but all questions unaswered ?
is it so hard to make a config like
I think you can just leave the -b flag off completely now.
For those who come along later, note that MPG123 only supports mpeg3 files, and many radio stations are now streaming MPEG4. To get that to work, you’ll need to figure out how to install VLC and to get it to work.
It may also be a good idea to update mpg123 to a newer version. The version distributed with FreePBX is somewhat buggy and may result in dead streams.
Also, note that when you set-up streaming MOH, the stream runs non-stop, 24/7, even when nobody is listening to the MOH…