[Asterisk-Users] Asterisk causing server to hang ... any hints?

beonice beonice at yahoo.com
Tue Feb 8 16:40:37 MST 2005


I am trying to set up a simple Asterisk server. All
it's going to do for now is to act as my voicemail
box. I've got a DID from Voicepulse, and am using IAX
(I'll get to SIP someday when I want to circumvent the
phone company for long-distance, but for now I'd be
happy to get a trial version of Asterisk running).

So far, I've managed to set up voicemail.conf,
extensions.conf and iax.conf so that incoming calls
are answered and a voicemail can be left. Initially I
did not have a handler for the timeout case, and
Asterisk would complain about the missing handler and
occasionally would crash the server after several
messages had been left (I'm the only one testing it,
and the server has nothing else running, just
Asterisk), requiring a hard reboot. 

To avoid this, I put in a handler for the timeout.
Now, Asterisk crashes the server as soon as I leave
myself a message! This is irritating. Hard reboots
everytime someone leaves me a voicemail is not going
to be something I can trust if I go on vacation
(hopefully someday soon).

Any ideas what I am doing wrong?

Here's the change I made to my extension file (this
used to crash occasionally):
[old-context]
exten => 7777,2,VoiceMail,u7777
exten => 7777,3,Hangup
exten => 7777,102,VoiceMail,b7777
exten => 7777,3,Hangup
exten => 7777,103,Hangup


[new-context] ;; crashes all the time!
exten => 7777,2,VoiceMail,u7777
exten => 7777,3,Hangup
exten => 7777,102,VoiceMail,b7777
exten => 7777,3,Hangup
exten => 7777,103,Hangup
exten => 8888,1,Playback(transfer,skip)
exten => 8888,2,Ringing
exten => 8888,3,Wait(2)
exten => 8888,4,VoiceMail,u8888
exten => 8888,104,VoiceMail,b8888
exten => 1001,1,Ringing
exten => 1001,2,Wait(2)
exten => 1001,3,VoicemailMain
exten => _NXXNXXXXXX,1,Background(beep)
;exten => _NXXNXXXXXX,2,SayDigits(${EXTEN})
;exten => _NXXNXXXXXX,3,Goto(testdtmf|s|1)
exten => t,1,Ringing
exten => t,2,Hangup
exten => i,1,Ringing
exten => i,2,Hangup
exten => a,1,VoicemailMain,EXTEN
exten => a,2,Hangup

I thought that using the 
exten => t,2,Hangup and the
exten => i,2,Hangup
would cause Asterisk to hang up on timeout, but
obviously I misunderstood. By the way, what _does_ the
'a' handler do, anyway? I believe 'i' is for invalid
key and 't' is for timeout. I'm not sure what 'a'
does.

The last time I tried to leave myself voicemail,
here's the output I got. And yes, it crashed. I've got
Asterisk running at a level of 4 in terms of
verbosity, i.e., I start it with /usr/sbin/asterisk
-vvvvcp

    -- Playing 'beep' (language 'en')
Feb  8 14:07:29 DEBUG[4195]: chan_iax2.c:5310
socket_read: Ooh, voice format changed to 4
  == CDR updated on
IAX2/voicepulse-in-01 at 66.234.228.170:4569/1
    -- Executing
Playback("IAX2/voicepulse-in-01 at 66.234.228.170:4569/1",
"transfer|skip") in new stack
    -- Playing 'transfer' (language 'en')
    -- Executing
VoiceMail("IAX2/voicepulse-in-01 at 66.234.228.170:4569/1",
"u7777") in new stack
Feb  8 14:07:42 DEBUG[4195]: app_voicemail.c:1381
leave_voicemail:
voicemail/voicepulse_connect_context/7777/unavail
doesn't exist, doing what we can
    -- Playing 'vm-theperson' (language 'en')
    -- Playing 'digits/7' (language 'en')
    -- Playing 'digits/7' (language 'en')
    -- Playing 'digits/7' (language 'en')
    -- Playing 'digits/7' (language 'en')
    -- Playing 'vm-isunavail' (language 'en')
    -- Playing 'vm-intro' (language 'en')
    -- Playing 'beep' (language 'en')
    -- Recording the message
Feb  8 14:07:53 DEBUG[4195]: app.c:549
ast_play_and_record: play_and_record: <None>,
/var/spool/asterisk/voicemail/voicepulse_connect_context/7777/INBOX/msg0001,
'wav49|gsm|wav'
Feb  8 14:07:53 DEBUG[4195]: app.c:566
ast_play_and_record: Recording Formats: sfmts=wav49
    -- x=0, open writing: 
/var/spool/asterisk/voicemail/voicepulse_connect_context/7777/INBOX/msg0001
format: wav49, 0x814ded0
    -- x=1, open writing: 
/var/spool/asterisk/voicemail/voicepulse_connect_context/7777/INBOX/msg0001
format: gsm, 0x814dff0
    -- x=2, open writing: 
/var/spool/asterisk/voicemail/voicepulse_connect_context/7777/INBOX/msg0001
format: wav, 0x814e100
    -- User ended message by pressing #
    -- Playing 'auth-thankyou' (language 'en')
localhost*CLI>

At this point, the server itself seems to hang. I can
do nothing but a physical reboot of the machine.

HELP.

Thanks,
BeOnIce.



		
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page – Try My Yahoo!
http://my.yahoo.com 



More information about the asterisk-users mailing list