Checking Voicemail

Hi, I’m having some issues listening to my voicemail on the asterisk server I set up.

I am able to call someone and leavea a voicemail normally.

I am able to dial that persons voicemail extension, and it proceeds to inform me of the voicemails in my account.

I am able to say I want to listen to voicemails, and then it begins to give date/time of the voicemail, then disconnects, without playing the audio file.

The .wav and .gsm and .txt files are located in the /var/spool/asterisk subfolders.

Is there anything specific anyone could tell me to make sure I have formatted correctly?

Here is the basic idea for all my users in sip/voicemail/extensions.

voicemail.conf:

[general]
attach=no
format=wav49|gsm
maxlogins=5
minmessage=1
maxmessage=60
forcename=yes
forcegreeting=yes
maxmsg=100
tz=eastern

[RA]
1111 => Name, email
2222 => Name, email
etc.

sip

[general]
context=default
bindaddr=10.10.10.17
bindport=5060
srvlookup=yes

[Name]
type=friend
username=name
secret=password
host=dynamic
context=lab
mailbox=1110@RA
disallow=all
allow=ulaw
allow=gsm
language=en

and extensions:

[general]
static=yes
writeprotect=no

[globals]
CONSOLE=Console/dsp
IAXINFO=guest
TRUNK=Zap/g2
TRUNKMS1

[lab]
exten =>1111,1,Dial(SIP/name|20)
exten =>1111,2,VoiceMail(1111@RA)
exten =>1111,3,Playback(vm-goodbye)
exten =>1111,4,wait(2)
exten =>1111,5,HangUp()

etc.

include =>voicemail

[voicemail]
exten => 1110,1,Answer()
exten => 1110,2,VoiceMailMain(1111@RA)
exten => 1110,3,HangUp()

etc.

here is the output for the -rvvvv during the voicemail hangup:

...
    -- <SIP/chase-0184cc00> Playing 'digits/18' (language 'en')
    -- <SIP/chase-0184cc00> Playing 'digits/p-m' (language 'en')
[Jul 18 08:06:54] WARNING[483]: format_wav.c:140 check_header: Not a wav file 49
[Jul 18 08:06:54] WARNING[483]: file.c:311 fn_wrapper: Unable to open format wav
[Jul 18 08:06:54] WARNING[483]: file.c:809 ast_streamfile: Unable to open /var/spool/asterisk/voicemail/RA/1111/INBOX/msg0000 (format 0x4 (ulaw)): No such file or directory
  == Spawn extension (lab, 1110, 2) exited non-zero on 'SIP/chase-0184cc00'

anyone?

bump? Anyone have any comments?

What are the permissions on the wav file? Does asterisk have access to them?

post the output of:

ls -l /var/spool/asterisk/voicemail/RA/1111/INBOX

and

ps -C asterisk -f

Thanks for the reply swaterhouse. To be honest this is one thing that hadn’t dawned on me. If Asterisk created the file I assumed that it would be able to use it. Here is the output…

ls -l /var/spool/asterisk/voicemail/RA/1111/INBOX/
total 40
-rwx------   1 root  wheel    60 Jul 17 15:31 msg0000.WAV
-rwx------   1 root  wheel     0 Jul 17 15:31 msg0000.gsm
-rw-------   1 root  wheel   247 Jul 17 15:31 msg0000.txt
-rwx------   1 root  wheel  1880 Jul 20 10:26 msg0001.WAV
-rwx------   1 root  wheel  1848 Jul 20 10:26 msg0001.gsm
-rw-------   1 root  wheel   247 Jul 20 10:26 msg0001.txt

I changed permissions and I get the same output. Could it have something to do with running asterisk on OS X? Just a shot in the dark…

Problem solved…apparently OS X doesn’t like .WAV (wav49). I changed it to just wav(.wav), but it still saves the files as .WAV. Renaming the files to .wav plays back successfully.

After reading voip-info.org i understand why this happens, but could someone suggest an easy way to auto change all WAV files to wav files once a voicemail is left?

Otherwise I’ll just be using gsm…

You could run a script in your dialplan after the voicmail app returns. Not really a great option but it is an option.

You might want to submit this as a bug. I don’t think OSX is “supported” but maybe the could change the behavior.