[asterisk-users] how to play music when dial fail or time out

Matt Riddell lists at venturevoip.com
Tue May 10 22:24:24 CDT 2011


On 11/05/11 3:11 PM, John Wu wrote:
> Hi Enrico
> thanks I do what u said but meet this problem:
> [May 11 11:08:49] WARNING[4545]: file.c:650 ast_openstream_full: File
> fail.wav does not exist in any format
> [May 11 11:08:49] WARNING[4545]: file.c:953 ast_streamfile: Unable to
> open fail.wav (format 0x2 (gsm)): No such file or directory
> [May 11 11:08:49] WARNING[4545]: app_playback.c:471 playback_exec:
> ast_streamfile failed on SIP/IMSI460020656177633-00000000 for fail.wav

When you playback a file in Asterisk you don't provide the extension.

So you'd do Playback(fail) rather than Playback(fail.wav)

That way if you have 10 files all called fail (i.e. fail.wav, fail.gsm, 
fail.ulaw, fail.alaw etc etc) it will pick the one which matches the 
phone calls.

For example in the above example you were making a call in the GSM 
format but it couldn't find a file called fail.wav.gsm so it looked for 
fail.wav.* and couldn't find anything.

Basically just drop the extension.

-- 
Cheers,

Matt Riddell
_______________________________________________

http://www.venturevoip.com/news.php (Daily Asterisk News)
http://www.venturevoip.com/exchange.php (Full ITSP Solution)
http://www.venturevoip.com/cc.php (Call Centre Solutions)



More information about the asterisk-users mailing list