Upgraded from Asterisk 1.4 on CentOS 5.3 to Asterisk 10.1.3 on CentOS 6.2 on a new machine. I am still using the same dialplan. Now Asterisk will not play sound files using Background() application. Error is:
Executing [s@macro-ans_svc:3] BackGround(“DAHDI/2-1”, “/var/lib/asterisk/sounds/en/vm-goodbye”) in new stack
[Mar 3 22:28:08] WARNING[4699]: file.c:698 ast_openstream_full: File /var/lib/asterisk/sounds/en/vm-goodbye does not exist in any format
[Mar 3 22:28:08] WARNING[4699]: file.c:1021 ast_streamfile: Unable to open /var/lib/asterisk/sounds/en/vm-goodbye (format (ulaw)): No such file or directory
[Mar 3 22:28:08] WARNING[4699]: pbx.c:9939 pbx_builtin_background: ast_streamfile failed on DAHDI/2-1 for /var/lib/asterisk/sounds/en/vm-goodbye
I coded the full path and used the file vm-goodbye for testing. I have a custom main-menu_jv file that I ultimately want to use. I checked that vm-goodbye exists as a .wav and .gsm:
[root@asterisk en]# ls -l vm-goodbye.wav
-rw-r–r--. 1 root root 16104 Apr 25 2011 vm-goodbye.wav
[root@asterisk en]# pwd
/var/lib/asterisk/sounds/en
Dialplan: I updated my Macro() applications to Gosub() as documentation recommended, no luck.
[incoming_zap]
exten => s,1,Verbose(1,incoming call ZAP Exten s)
exten => s,n,Gosub(macro-ans_svc,s,1)
exten => s,n,Hangup()
[macro-ans_svc]
exten => s,1,Answer()
exten => s,n,Verbose(1,Answering Service Macro)
;exten => s,n,Background(main-menu_jv)
exten => s,n,BackGround(/var/lib/asterisk/sounds/en/vm-goodbye)
exten => s,n,WaitExten(5)
exten => s,n,Return()
exten => t,n,Hangup()
Also, my asterisk.conf shows:
astvarlibdir => /var/lib/asterisk
but if I change this to /var/lib/asterisk/sounds/en and restart Asterisk, is does not seem to change in the CLI>core show settings, command output. So I put the vm-goodbye.wav into the /var/lib/asterisk folder, and same problem.
I have searched similar problems in the forum and none of those fixed my problem. Permission level of all folders are 755.