[asterisk-users] 1.6.0.10: core restart on ReceiveFax()

sean darcy seandarcy2 at gmail.com
Tue Jun 16 19:57:39 CDT 2009


On Tue, Jun 16, 2009 at 10:13 AM, Miguel Molina<mmolina at millenium.com.co> wrote:
> sean darcy escribió:
>> For our internal fax machines, I'm checking if the faxes are going to
>> branch offices. If they are, I want to capture and email them to the
>> branches. I've set up extension 8447 to test this.
>>
>> A fax machines is connected via an SPA 2102 on 173. Any calls from 173
>> are sent to:
>>
>> [outbound-fax]
>> exten => 8447,1,Answer()
>> exten => 8447,n,GoSub(Capture-Fax,s,1)
>>
>> exten =>_NXXNXXXXXX,1,Answer()
>> exten =>_NXXNXXXXXX,n,GoSub(DialOut-PSTN,s,1(1${EXTEN}))
>>
>> exten =>_1NXXNXXXXXX,1,Answer()
>> exten =>_1NXXNXXXXXX,n,GoSub(DialOut-PSTN,s,1(${EXTEN}))
>>
>> exten =>_91NXXNXXXXXX,1,Answer()
>> exten =>_91NXXNXXXXXX,n,GoSub(DialOut-PSTN,s,1(${EXTEN:1}))
>>
>> Actual outbound faxes work correctly. That is, a call from 173 to an
>> outside fax machine works.
>>
>> The test faxes go to:
>>
>> [Capture-Fax]
>> exten =>
>> s,1,Set(FAXFILE=/var/spool/asterisk/fax/${STRFTIME(${EPOCH},,%Y%m%d)}_${STRFTIME(${EPOCH},,%H%M)})
>> exten => s,n,ReceiveFAX(${FAXFILE}.tif)  ;; 1.6 use ReceiveFAX
>> exten => s,n,Hangup()
>>
>> When the test fax gets to ReceiveFax() asterisk restarts. Any calls at
>> the time are lost.
>>
>>      -- Executing [8447 at outbound-fax:1] Answer("SIP/173-081d3780", "")
>> in new stack
>>      -- Executing [8447 at outbound-fax:2] Gosub("SIP/173-081d3780",
>> "Capture-Fax,s,1") in new stack
>>      -- Executing [s at Capture-Fax:1] Set("SIP/173-081d3780",
>> "FAXFILE=/var/spool/asterisk/fax/20090612_1710") in new stack
>>      -- Executing [s at Capture-Fax:2] ReceiveFAX("SIP/173-081d3780",
>> "/var/spool/asterisk/fax/20090612_1710.tif") in new stack
>>
>> /var/spool/asterisk/fax exists, permissions 777:
>>
>> ls -l /var/spool/asterisk
>> total 32
>> ..............
>> drwxrwxrwx 2 root root 4096 2009-05-03 14:21 fax
>> ...........
>>
>>
>> I've set debug and verbose to 20, but no further info.
>>
>> What am I missing? Anybody have something like this working this working?
>>
>> sean
>>
>>
>> _______________________________________________
>> -- 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
>>
> Two thoughts on this:
>
> 1. On Exten 8447, why are you using a GoSub instead of a simple Goto?
> (Shouldn't pose a problem, just curious)
> 2. I wouldn't recommend the use of date-time only to form the filename
> of the received fax. This was the key issue that was killing asterisk in
> my case, when I switched to date-time + uniqueid for example, everything
> went fine. That's because it looks like RxFax() or in this case
> ReceiveFax() doesn't play well with duplicate (open) filenames, which I
> don't know if they occur in your case. It definitely can happen if you
> have programmed it and have the capacity to receive simultaneous faxes
> at a time. After the change my machine is rock stable, receiving and
> sending hundreds of faxes a day with no restarts.
>
> Hope this helps.
>
> Cheers,
>
> --
> Ing. Miguel Molina
> Grupo de Tecnología
> Millenium Phone Center


I've started using GoSub  pretty often. No good reason. Just getting
beaten up in class when
I used goto's.

Interesting about the unique id's. But it's not yet my problem. An id
to the minute guarantees uniqueness for my testing.

And I've fixed the problem. I'm now using the new Digium Fax module. That works.

sean



More information about the asterisk-users mailing list