Asterisk CMD Voicemail fails to return on hangup

According to, voicemail will return the following results SUCCESS | USEREXIT | FAILED.

but it does not if user hangs up after leaving voicemail.

MOST PEOPLE IN THE WORLD HANG UP. so asking them to press # will not do.

I get:

[Dec 11 12:32:42] VERBOSE[30770] logger.c: – User hung up
[Dec 11 12:32:42] VERBOSE[30770] logger.c: == Spawn extension (leave_voicemail, s, 1) exited non-zero on ‘SIP/102-093c1e18’

this sounds like a bug to me.


have you added a Noop to check what is returned ? the exit result is returned in the VMSTATUS channel variable. add a Noop in the H extension to see what it is.


thanks, that did the job.

was not using extension h

exten => s,1,Voicemail(500|s)
exten => s,n(next),system(${SCRIPTS_DIR}/ 500)
exten => s,n,Hangup
exten => h,1,Verbose(${VMSTATUS})
exten => h,n,GotoIf($["${VMSTATUS}" = “SUCCESS”]?s,next)