Ken D'Ambrosio
2009-Jan-20 22:02 UTC
[asterisk-users] extensions.conf -- what to do when command throws errors?
Hi, all. I've got app_rxfax going and nicely receiving a fax, which I then throw to a script, and have it convert it to a PDF and mail it. Works great... a lot of the time. But a fair bit of the time, rxfax throws errors, and extensions.conf seems never to invoke my script. Here are the pertinent lines: exten => _6403,n,rxfax(${FAXFILE}) exten => _6403,n,System(/usr/local/bin/fax-sender.py ${FAXFILE}) Now the problem here is that the .TIF file is received just fine, so, errors or no, I'd like to get to the script. Instead, I get this: ... [5410] /tmp/spandsp/agx-ast-addons/trunk/app_rxfax.c: Channel T30 DONE < 0. [5410] /tmp/spandsp/agx-ast-addons/trunk/app_rxfax.c: Channel T30 DONE < 0. [5410] logger.c: == Auto fallthrough, channel 'Zap/4-1' status is 'UNKNOWN' [5410] chan_zap.c: Set option AUDIO MODE, value: ON(1) on Zap/4-1 [5410] chan_zap.c: Not yet hungup... Calling hangup once with icause, and clearing call [5410] chan_zap.c: Set option AUDIO MODE, value: OFF(0) on Zap/4-1 [5410] logger.c: -- Hungup 'Zap/4-1' ... In an ideal world, getting rid of the "Channel T30 DONE <0" errors would be great, but I'll take run-the-script-when-it's-done-regardless, instead. Note, however, that I can't just call it from extension i, because I need to pass it information, and don't want it executing on errant voice calls. Suggestions? Thanks! -Ken
Danny Nicholas
2009-Jan-20 22:07 UTC
[asterisk-users] extensions.conf -- what to do when command throwserrors?
It seems to me that $FAXFILE lives in the 6403 context, not the n, so it would still be useable. If this isn't the case, I'd call an AGI script in the "I" context. -----Original Message----- From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Ken D'Ambrosio Sent: Tuesday, January 20, 2009 4:03 PM To: asterisk-users at lists.digium.com Subject: [asterisk-users] extensions.conf -- what to do when command throwserrors? Hi, all. I've got app_rxfax going and nicely receiving a fax, which I then throw to a script, and have it convert it to a PDF and mail it. Works great... a lot of the time. But a fair bit of the time, rxfax throws errors, and extensions.conf seems never to invoke my script. Here are the pertinent lines: exten => _6403,n,rxfax(${FAXFILE}) exten => _6403,n,System(/usr/local/bin/fax-sender.py ${FAXFILE}) Now the problem here is that the .TIF file is received just fine, so, errors or no, I'd like to get to the script. Instead, I get this: ... [5410] /tmp/spandsp/agx-ast-addons/trunk/app_rxfax.c: Channel T30 DONE < 0. [5410] /tmp/spandsp/agx-ast-addons/trunk/app_rxfax.c: Channel T30 DONE < 0. [5410] logger.c: == Auto fallthrough, channel 'Zap/4-1' status is 'UNKNOWN' [5410] chan_zap.c: Set option AUDIO MODE, value: ON(1) on Zap/4-1 [5410] chan_zap.c: Not yet hungup... Calling hangup once with icause, and clearing call [5410] chan_zap.c: Set option AUDIO MODE, value: OFF(0) on Zap/4-1 [5410] logger.c: -- Hungup 'Zap/4-1' ... In an ideal world, getting rid of the "Channel T30 DONE <0" errors would be great, but I'll take run-the-script-when-it's-done-regardless, instead. Note, however, that I can't just call it from extension i, because I need to pass it information, and don't want it executing on errant voice calls. Suggestions? Thanks! -Ken _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Steve Edwards
2009-Jan-20 22:44 UTC
[asterisk-users] extensions.conf -- what to do when command throws errors?
On Tue, 20 Jan 2009, Ken D'Ambrosio wrote:> Hi, all. I've got app_rxfax going and nicely receiving a fax, which I > then throw to a script, and have it convert it to a PDF and mail it. > Works great... a lot of the time. But a fair bit of the time, rxfax > throws errors, and extensions.conf seems never to invoke my script. Here > are the pertinent lines: > > exten => _6403,n,rxfax(${FAXFILE}) > exten => _6403,n,System(/usr/local/bin/fax-sender.py ${FAXFILE})What else can match _6403 other than 6403? Wouldn't "exten = 6403,n,..." be "better?"> [5410] logger.c: == Auto fallthrough, channel 'Zap/4-1' status is 'UNKNOWN'"Auto fallthrough" happens when Asterisk wants to go to the next priority and there isn't one. Does "[show dialplan|dialplan show] <context-containing-rxfax>" look like? Any chance rxfax is trying to do a "jump +101" on you? Thanks in advance, ------------------------------------------------------------------------ Steve Edwards sedwards at sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000