4

I've setup an IVR to pickup up incoming calls to allow them to enter an extension or press one to be dropped into the ring group for our office. The only issue is Asterisk isn't playing the WAV/MP3/GSM audio file I upload. Using a default recording works , I'm not sure why mine won't. I also know the IVR works because I can enter an extension after it stops ringing. I am using Elastix as a GUI to Asterisk.

Here's a snippet of the "full" log file as contained in /var/log/asterisk:


[Dec 30 22:48:12] VERBOSE[4296] pbx.c:     -- Executing [s@from-pstn:1] Set("DAHDI/1-1", "__FROM_DID=s") in new stack
[Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:2] Gosub("DAHDI/1-1", "app-blacklist-check,s,1") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@app-blacklist-check:1] GotoIf("DAHDI/1-1", "0?blacklisted") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@app-blacklist-check:2] Set("DAHDI/1-1", "CALLED_BLACKLIST=1") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@app-blacklist-check:3] Return("DAHDI/1-1", "") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:3] ExecIf("DAHDI/1-1", "1 ?Set(CALLERID(name)=)") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:4] Ringing("DAHDI/1-1", "") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:5] Set("DAHDI/1-1", "__CALLINGPRES_SV=allowed_not_screened") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:6] Set("DAHDI/1-1", "CALLERPRES()=allowed_not_screened") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@from-pstn:7] Goto("DAHDI/1-1", "ivr-3,s,1") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Goto (ivr-3,s,1) [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:1] Set("DAHDI/1-1", "MSG=custom/Untitled24") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:2] Set("DAHDI/1-1", "LOOPCOUNT=0") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:3] Set("DAHDI/1-1", "__DIR-CONTEXT=") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:4] Set("DAHDI/1-1", "_IVR_CONTEXT_ivr-3=") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:5] Set("DAHDI/1-1", "_IVR_CONTEXT=ivr-3") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:6] GotoIf("DAHDI/1-1", "0?begin") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:7] Answer("DAHDI/1-1", "") in new stack [Dec 30 22:48:12] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:8] Wait("DAHDI/1-1", "1") in new stack [Dec 30 22:48:14] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:9] Set("DAHDI/1-1", "TIMEOUT(digit)=3") in new stack [Dec 30 22:48:14] VERBOSE[4296] func_timeout.c: -- Digit timeout set to 3.000 [Dec 30 22:48:14] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:10] Set("DAHDI/1-1", "TIMEOUT(response)=20") in new stack [Dec 30 22:48:14] VERBOSE[4296] func_timeout.c: -- Response timeout set to 20.000 [Dec 30 22:48:14] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:11] Set("DAHDI/1-1", "__IVR_RETVM=") in new stack [Dec 30 22:48:14] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:12] ExecIf("DAHDI/1-1", "1?Background(custom/Untitled24)") in new stack [Dec 30 22:48:14] WARNING[4296] format_wav.c: Not a wav file 49 [Dec 30 22:48:14] WARNING[4296] file.c: Unable to open format wav [Dec 30 22:48:14] WARNING[4296] file.c: Unable to open custom/Untitled24 (format 0x4 (ulaw)): No such file or directory [Dec 30 22:48:14] WARNING[4296] pbx.c: ast_streamfile failed on DAHDI/1-1 for custom/Untitled24 [Dec 30 22:48:14] VERBOSE[4296] pbx.c: -- Executing [s@ivr-3:13] WaitExten("DAHDI/1-1", ",") in new stack [Dec 30 22:48:16] VERBOSE[4297] pbx.c: == Spawn extension (ivr-3, s, 13) exited non-zero on 'DAHDI/3-1' [Dec 30 22:48:16] VERBOSE[4297] pbx.c: -- Executing [h@ivr-3:1] Hangup("DAHDI/3-1", "") in new stack [Dec 30 22:48:16] VERBOSE[4297] pbx.c: == Spawn extension (ivr-3, h, 1) exited non-zero on 'DAHDI/3-1' [Dec 30 22:48:16] VERBOSE[4297] sig_analog.c: -- Hanging up on 'DAHDI/3-1' [Dec 30 22:48:16] VERBOSE[4297] chan_dahdi.c: -- Hungup 'DAHDI/3-1'
Peter Grace
  • 3,446
  • 1
  • 26
  • 42
Jacob
  • 9,114
  • 4
  • 44
  • 56
  • 1
    Can you please amend your question with the extension syntax in question and also the log of the console when you call the extension? – Peter Grace Dec 30 '11 at 21:56

1 Answers1

4

In your output, there is an error from the format_wav.c module saying the input is not a wav file. Check your format and make sure that you're saving it in the format Asterisk expects.

As a workaround, you can use the open source audio tool "sox" to make things a little easier: sox /var/lib/asterisk/sounds/custom/Untitled24.wav -r 8000 -c 1 /var/lib/asterisk/sounds/custom/Untitled24.gsm resample -ql

This will create a GSM format of the file and should cause your extension logic to work properly.

Peter Grace
  • 3,446
  • 1
  • 26
  • 42