Hi. I’m trying to get Asterisk to play with Cisco CallManager to provide VoiceMail. It’s a very simple CCM system that does not require extensive access control and is not using Partitions or Calling Search Space. The desire to use Asterisk solely for VoiceMail (VM) and nothing else at this time. Asterisk and CCM are on different subnets on my internal network. Two CallManagers are present, CCM1 and CCM2, with CCM1 (xxx.xxx.xxx.102) as the Publisher and the Media Termination Point
(MTP) stuff on CCM2 (xxx.xxx.xxx.103) as the Subscriber. My CCM extension is 7419 and desired VM box is 7419. A second account 7414 was created for another extension for testing with, same issues.
I’d really appreciate any help. I’ve been at it for a few weeks off and on and scoured the Internet but am about at a loss… TIA!
Parts:
Cisco CallManager 4.1(3)
Asterisk 1.2.7.1
Cisco 2811 Voice Gateway attached to a PRI for PSTN access
Cisco 7960 handsets
Configured per Wiki:
voip-info.org/tiki-index.php … ntegration
Copied Wiki except VM pilot changed to 6500 from 8888. I think parts of the problem may be related to:
-
The Wiki entry lists Asterisk 1.0.8 but I am using 1.2.x? It appears that aspects of the VM and other commands have changed syntax from 1.0.x to 1.2.x but I can’t track exactly what.
-
I’m using two CallManagers where I think the Wiki has one.
-
I’ve got a Cisco 2800 router in the mix where I don’t think the Wiki has one.
I’m able to:
Manually enable/disable MWI by dialing the numbers on the handset.
Dial the VM pilot number to access VM.
Hit the “messages” button to access VM.
Change password, record greetings, etc.
I’m unable to:
Have a no answer/busy call roll into VM internally.
Have a no answer/busy call roll into VM externally (PSTN > PRI > Cisco 2811 Voice Gateway > AutoAttendant).
Leave a message in my own inbox or on another inbox on the system by using 3 (advanced options ), 5 (leave message).
SIP debug when call leaves CCM and goes into Asterisk:
*CLI> – Executing GotoIf(“SIP/xxx.xxx.xxx.102-085d93c0”, “7419?2:400”) in new stack
– Goto (incoming,6500,2)
– Executing MailboxExists(“SIP/xxx.xxx.xxx.102-085d93c0”, “7419@default”) in new stack
– Executing Congestion(“SIP/xxx.xxx.xxx.102-085d93c0”, “”) in new stack
== Spawn extension (incoming, 6500, 3) exited non-zero on ‘SIP/xxx.xxx.xxx.102-085d93c0’
SIP debug when I try to leave a message to my own extension from within VM:
Jun 13 20:15:19 WARNING[28152]: app_voicemail.c:2411 leave_voicemail: No entry in voicemail config file for ‘7419’
– Playing ‘vm-opts’ (language ‘en’)
SIP debug upon hangup after failing to leave myself a message:
== Spawn extension (incoming, 6500, 400) exited non-zero on ‘SIP/xxx.xxx.xxx.102-09cd8a70’
/var/lib/asterisk/scripts/vm.sh: line 37: -default: command not found
– Attempting call on Local/2307419 for wait@default:1 (Retry 1)
– Executing SetCallerID(“Local/2307419@default-da58,2”, “7419”) in new stack
– Executing Dial(“Local/2307419@default-da58,2”, “SIP/28888@xxx.xxx.xxx.103”) in new stack
– Called 28888@xxx.xxx.xxx.103
– Got SIP response 500 “Internal Server Error” back from xxx.xxx.xxx.103
– SIP/xxx.xxx.xxx.103-1512 is circuit-busy
== Everyone is busy/congested at this time (1:0/1/0)
– Executing Answer(“Local/2307419@default-da58,2”, “”) in new stack
> Channel Local/2307419@default-da58,1 was answered.
== Starting Local/2307419@default-da58,1 at default,wait,1 failed so falling back to exten ‘s’
== Starting Local/2307419@default-da58,1 at default,s,1 still failed so falling back to context ‘default’
– Executing Wait(“Local/2307419@default-da58,2”, “1”) in new stack
Jun 13 20:15:31 WARNING[28165]: pbx.c:2354 __ast_pbx_run: Channel ‘Local/2307419@default-da58,1’ sent into invalid
extension ‘s’ in context ‘default’, but no invalid handler
== Spawn extension (default, 2307419, 4) exited non-zero on 'Local/2307419@default-da58,2’
Jun 13 20:15:31 NOTICE[28165]: pbx_spool.c:279 attempt_thread: Call completed to Local/2307419
Asterisk configs:
//sip.conf//
[general]
qualify=yes
;context=default ; Default context for incoming calls
[ccm1]
;type=friend
type=peer
context=incoming
host=xxx.xxx.xxx.102
ipaddr=xxx.xxx.xxx.102
disallow=all
allow=ulaw
allow=alaw
;nat=no
nat=yes
canreinvite=yes
qualify=yes
mailbox=7419@default
mailbox=7414@default
usereqphone=yes
[ccm2]
;type=friend
type=peer
context=incoming
host=xxx.xxx.xxx.103
ipaddr=xxx.xxx.xxx.103
disallow=all
allow=ulaw
allow=alaw
;nat=no
nat=yes
canreinvite=yes
qualify=yes
mailbox=7419@default
mailbox=7414@default
usereqphone=yes
bindport=5060 ; UDP Port to bind to (SIP standard port is 5060)
bindaddr=0.0.0.0 ; IP address to bind to (0.0.0.0 binds to all)
srvlookup=yes ; Enable DNS SRV lookups on outbound calls
; Note: Asterisk only uses the first host
; in SRV records
; Disabling DNS SRV lookups disables the
; ability to place SIP calls based on domain
; names to some other SIP users on the Internet
dtmfmode = rfc2833 ; Set default dtmfmode for sending DTMF. Default: rfc2833
//voicemail.con//
[general]
; Default formats for writing Voicemail
;format=g723sf|wav49|wav
format=wav49|gsm|wav
sendvoicemail=yes
; Who the e-mail notification should appear to come from
serveremail=asterisk@foo.bar
; Should the email contain the voicemail as an attachment
attach=yes
; How many miliseconds to skip forward/back when rew/ff in message playback
skipms=3000
; How many seconds of silence before we end the recording
maxsilence=10
; Silence threshold (what we consider silence, the lower, the more sensitive)
silencethreshold=128
; Max number of failed login attempts
maxlogins=3
externnotify=/var/lib/asterisk/scripts/vm.sh
emaildateformat=%A, %B %d, %Y at %r
sendvoicemail=yes ; Context to Send voicemail from [option 5 from the advanced menu]
[zonemessages]
eastern=America/New_York|‘vm-received’ Q ‘digits/at’ IMp
central=America/Chicago|‘vm-received’ Q ‘digits/at’ IMp
central24=America/Chicago|‘vm-received’ q ‘digits/at’ H N 'hours’
military=Zulu|‘vm-received’ q ‘digits/at’ H N ‘hours’ ‘phonetic/z_p’
[default]
; Define maximum number of messages per folder for partcular context.
;maxmsg=50
7419 => 1111,Foo Bar,foo.bar@fubar.com,saycid=yes
7414 => 1111,Boo Far,boo.far@fubar.com
//extnesions.conf//
[general]
;
; If static is set to no, or omitted, then the pbx_config will rewrite
; this file when extensions are modified. Remember that all comments
; made in the file will be lost when that happens.
;
; XXX Not yet implemented XXX
;
static=yes
writeprotect=no
autofallthrough=yes
clearglobalvars=no
priorityjumping=no
[globals]
TRUNK=SIP/xxx.xxx.xxx.103
TRUNKMSD=1
[incoming]
;Handle VM
exten => 6500,1,GoToIf($[${RDNIS}]?2:400)
exten => 6500,2,MailboxExists(${RDNIS}@default)
exten => 6500,3,Congestion
exten => 6500,103,Voicemail(su${RDNIS})
exten => 6500,104,Playback(vm-goodbye)
exten => 6500,105,Hangup
exten => 6500,400,VoicemailMain
[default]
;MWI off/on; shaunewing
exten => _230XXXX,1,SetCallerID(${EXTEN:3})
exten => _230XXXX,2,Dial(SIP/28888@xxx.xxx.xxx.103)
exten => _230XXXX,3,Answer
exten => _230XXXX,4,Wait,1
exten => _230XXXX,5,Hangup
exten => _231XXXX,1,SetCallerID(${EXTEN:3})
exten => _231XXXX,2,Dial(SIP/28889@xxx.xxx.xxx.103)
exten => _231XXXX,3,Answer
exten => _231XXXX,4,Wait,1
exten => _231XXXX,5,Hangup
[macro-dialout-callmanager]
exten => s,1,ChanIsAvail(SIP/ccm2)
exten => s,2,Cut(AVAILCHAN=AVAILCHAN,1)
exten => s,3,Dial(${AVAILCHAN}/${ARG1})
exten => s,4,Hangup
exten => s,102,Congestion
[outgoing]
exten => _XXXX,1,Macro(dialout-callmanager,${EXTEN})
exten => _9NXXXXXX,1,Macro(dialout-callmanager,${EXTEN})
exten => _91NXXNXXXXXX,1,Macro(dialout-callmanager,${EXTEN})
exten => i,1,Congestion