Ray Van Dolson
2005-Sep-30 16:33 UTC
[Asterisk-Users] Music on hold not initiating RTP stream?
I've been having problems getting MusicOnHold to work, so I've dumbed
down my
setup to as simple of a setup as I can.
Asterisk 1.0.9. SIP ATA's (Sipura SPA-2002's)
<SIP ATA 1> <---> <Asterisk> <---> <SIP ATA 2>
Both ATA's have public IP's. No NAT'ing going on here. Reinvites
are allowed
so the media stream bypases Asterisk once a call is established.
The ATA's are Sipura SPA-2002's and I have MOH Server set to 899 on
each.
In Asterisk I have the following extension defined.
exten => 899,1,Answer
exten => 899,2,NoOp,${EXTEN}
exten => 899,3,NoOp,${RDNIS}
exten => 899,4,MusicOnHold(random)
exten => 899,5,Hangup
If I dial extension 899 directly, I hear the music I've chosen as expected.
This tells me that mpg123 is not the problem ;)
However, with a call in progress, if I hit hold or flash on SIP ATA 1, it
behaves correctly, but no music on hold is heard on SIP ATA 2. I can see in
my Asterisk console that MusicOnHold() gets called and tcpdump shows the
INVITE that first sets the RTP source to 0.0.0.0 then sets it to the IP of my
Asterisk box.
However, no RTP stream initiates, thus no music on hold is played.
I'm going to dig into the RFC a little to see how this is supposed to work,
but any ideas from what I've described? I know others are doing this
without
any problems.
Oh yeah, and my musiconhold.conf file:
random => quietmp3:/var/lib/asterisk/mohmp3,-z
Thanks in advance.
Ray
Kevin P. Fleming
2005-Sep-30 16:47 UTC
[Asterisk-Users] Music on hold not initiating RTP stream?
Ray Van Dolson wrote:> The ATA's are Sipura SPA-2002's and I have MOH Server set to 899 on each.Take that out, you don't need it.> However, with a call in progress, if I hit hold or flash on SIP ATA 1, it > behaves correctly, but no music on hold is heard on SIP ATA 2. I can see in > my Asterisk console that MusicOnHold() gets called and tcpdump shows the > INVITE that first sets the RTP source to 0.0.0.0 then sets it to the IP of my > Asterisk box.None of this is needed; Asterisk will stream MOH to ATA 2 all by itself, just by the fact that ATA 1 put ATA 2 on hold. You have over-complexified the setup :-)