[Asterisk-Users] MusicOnHold spawns everlasting mpg123 processes
Hullo :) I'm using CVS-04/23/04-23 from the stable 1.0 branch on kernel 2.6 - since I have no Digium h/w, I've just managed to get the zaprtc module to compile and run, so I thought the best way to test it would be via MoH. The MP3Player application works great .. exten = 6901,1,Answer exten = 6901,2,MP3Player(http://127.0.0.1:85/ES/28) This will play callers BBC Radio 4 from my local streaming setup, and when they hangup, the mpg123 process dies immediately. Perfect :) Unfortunately, the same cannot be said about: exten = 6900,1,Answer exten = 6900,2,MusicOnHold -- Accepting AUTHENTICATED call from 10.0.0.74, requested format = 2, actual format = 2 -- Executing Answer([EMAIL PROTECTED]/5, ) in new stack -- Executing MusicOnHold([EMAIL PROTECTED]/5, ) in new stack -- Started music on hold, class 'default', on [EMAIL PROTECTED]/5 Then I press 'Hangup' in IaxComm: -- Stopped music on hold on [EMAIL PROTECTED]/5 == Spawn extension (default, 6900, 2) exited non-zero on '[EMAIL PROTECTED]/5' -- Hungup '[EMAIL PROTECTED]/5' Alas, the 'mpg123' processes live on... 4049 pts/22 S 0:00 \_ asterisk -vc 4050 pts/22 S 0:00 | \_ mpg123 -q -s --mono -r 8000 -b 2048 -f 8192 sample-hold.mp3 4063 pts/22 S 0:00 | \_ mpg123 -q -s --mono -r 8000 -b 2048 -f 8192 sample-hold.mp3 In fact, if I redial ext 6900, I get played the MoH sample from the point at which mpg123 has reached in the mp3, rather than getting it from the start. The MusicOnHold docs say: Returns -1 on hangup. Never returns otherwise. I beg to differ :) Is this a bug, or have I made some fundamental mistake? Cheers, Gavin. ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] MusicOnHold spawns everlasting mpg123 processes
Actually, I think this is a feature. Rather than startup a new instance of mpg123 each time someone goes on hold, one instance per MOH class is created and used for all calls of that class. -brian Gavin Hamill wrote: Hullo :) I'm using CVS-04/23/04-23 from the stable 1.0 branch on kernel 2.6 - since I have no Digium h/w, I've just managed to get the zaprtc module to compile and run, so I thought the best way to test it would be via MoH. The MP3Player application works great .. exten = 6901,1,Answer exten = 6901,2,MP3Player(http://127.0.0.1:85/ES/28) This will play callers BBC Radio 4 from my local streaming setup, and when they hangup, the mpg123 process dies immediately. Perfect :) Unfortunately, the same cannot be said about: exten = 6900,1,Answer exten = 6900,2,MusicOnHold -- Accepting AUTHENTICATED call from 10.0.0.74, requested format = 2, actual format = 2 -- Executing Answer([EMAIL PROTECTED]/5, ) in new stack -- Executing MusicOnHold([EMAIL PROTECTED]/5, ) in new stack -- Started music on hold, class 'default', on [EMAIL PROTECTED]/5 Then I press 'Hangup' in IaxComm: -- Stopped music on hold on [EMAIL PROTECTED]/5 == Spawn extension (default, 6900, 2) exited non-zero on '[EMAIL PROTECTED]/5' -- Hungup '[EMAIL PROTECTED]/5' Alas, the 'mpg123' processes live on... 4049 pts/22 S 0:00 \_ asterisk -vc 4050 pts/22 S 0:00 | \_ mpg123 -q -s --mono -r 8000 -b 2048 -f 8192 sample-hold.mp3 4063 pts/22 S 0:00 | \_ mpg123 -q -s --mono -r 8000 -b 2048 -f 8192 sample-hold.mp3 In fact, if I redial ext 6900, I get played the MoH sample from the point at which mpg123 has reached in the mp3, rather than getting it from the start. The MusicOnHold docs say: Returns -1 on hangup. Never returns otherwise. I beg to differ :) Is this a bug, or have I made some fundamental mistake? Cheers, Gavin. ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] MusicOnHold spawns everlasting mpg123 processes
On Sun, Apr 25, 2004 at 03:52:57PM -0400, Brian Cuthie wrote: Actually, I think this is a feature. Rather than startup a new instance of mpg123 each time someone goes on hold, one instance per MOH class is created and used for all calls of that class. Right - now that I've stepped back and run that through my Logic-O-Tron 3000, I guess that makes sense, else each person would get the first piece of music each time... maybe this should be an option? Or at the very least, the present behaviour should be documented? :) Cheers, Gavin. ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users