Fax sometimes work?

I seem to be having some sort of intermittent problem with incoming faxes. Sometimes they come through, sometimes they don’t.

Below is a link to a basic diagram of the phone system lines.
http://smg.photobucket.com/albums/v329/bobismighty/pbx/?action=view&current=PublicPBXDiagram.jpg

All faxes come in the 0303 line and these are just regular tele lines, not voip.
I’m running 2.5.1.1 on Trixbox. Here are the only fax settings I have set:

General Settings:
Extension of fax machine for receiving faxes: system
Email address to have faxes emailed to: [email protected]
Email address that faxes appear to come from: [email protected]

Inbound route - Any CID/DID
Fax Extension: FreePBX Default
Fax Email: (blank)
Fax Detection Type: None
Pause After Answer: (blank)

Now, I’ve tried fooling around with changing all of these settings around, but have no luck.
I really just want faxes to be directed through the passthrough line in FXO2 to the server and have them handled there.

One thing I just noticed is that it seems like incoming faxes cause asterisk to reload. After it “handles” the fax, everything gets reloaded and the uptime resets. It doesn’t always does this, and it definitely didn’t used to do it.\

The weird thing is that even though FreePBX logs show it handling the fax, sometimes it passes through to the fax server and sometimes it doesn’t. I don’t really understand it. I’ll include the log of what happens when a fax hits the line.

Another weird thing that just happened is that the pbx just emailed me fax(which hasn’t happened in ages, only when I initially set it up and was testing), but the PDF of the fax would not open.

Basically, sometimes it goes through to the server, sometimes the PBX actually emails it(rarely, and with a corrupt pdf), and most of the time it just disappears.

Help?

[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] Set("Zap/2-1", "DID=s") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] NoOp("Zap/2-1", "DID is now s") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:4] GotoIf("Zap/2-1", "1?zapok:notzap") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Goto (from-zaptel-custom,s,6)
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:6] NoOp("Zap/2-1", "Is a Zaptel Channel") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:7] Set("Zap/2-1", "CHAN=2-1") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:8] Set("Zap/2-1", "CHAN=2") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:9] Macro("Zap/2-1", "from-zaptel-2|s|1") in new stack
[Jan 23 11:50:51] WARNING[3687] app_macro.c: No such context 'macro-from-zaptel-2' for macro 'from-zaptel-2'
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:10] NoOp("Zap/2-1", "Returned from Macro from-zaptel-2 - No match") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:11] Goto("Zap/2-1", "ext-did|s|1") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Goto (ext-did,s,1)
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] Set("Zap/2-1", "__FROM_DID=s") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] Gosub("Zap/2-1", "app-blacklist-check|s|1") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] LookupBlacklist("Zap/2-1", "") in new stack
[Jan 23 11:50:51] WARNING[3687] app_lookupblacklist.c: LookupBlacklist is deprecated.  Please use ${BLACKLIST()} instead.
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] GotoIf("Zap/2-1", "0?blacklisted") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] Return("Zap/2-1", "") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] ExecIf("Zap/2-1", "0 |Set|CALLERID(name)=6153508484") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:4] Set("Zap/2-1", "__CALLINGPRES_SV=allowed_not_screened") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:5] SetCallerPres("Zap/2-1", "allowed_not_screened") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:6] Goto("Zap/2-1", "timeconditions|1|1") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Goto (timeconditions,1,1)
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] GotoIfTime("Zap/2-1", "08:30-17:30|mon-fri|*|*?ivr-3|s|1") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Goto (ivr-3,s,1)
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] Set("Zap/2-1", "MSG=custom/Welcome") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] Set("Zap/2-1", "LOOPCOUNT=0") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] Set("Zap/2-1", "__DIR-CONTEXT=default") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:4] Set("Zap/2-1", "_IVR_CONTEXT_ivr-3=") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:5] Set("Zap/2-1", "_IVR_CONTEXT=ivr-3") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:6] GotoIf("Zap/2-1", "0?begin") in new stack
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:7] Answer("Zap/2-1", "") in new stack
[Jan 23 11:50:51] DEBUG[3687] chan_zap.c: Took Zap/2-1 off hook
[Jan 23 11:50:51] DEBUG[3687] chan_zap.c: No echo training requested
[Jan 23 11:50:51] VERBOSE[3687] logger.c:     -- Executing [[email protected]:8] Wait("Zap/2-1", "1") in new stack
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Executing [[email protected]:9] Set("Zap/2-1", "TIMEOUT(digit)=3") in new stack
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Digit timeout set to 3
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Executing [[email protected]:10] Set("Zap/2-1", "TIMEOUT(response)=4") in new stack
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Response timeout set to 4
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Executing [[email protected]:11] Set("Zap/2-1", "__IVR_RETVM=") in new stack
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- Executing [[email protected]:12] ExecIf("Zap/2-1", "1|Background|custom/Welcome") in new stack
[Jan 23 11:50:52] VERBOSE[3687] logger.c:     -- <Zap/2-1> Playing 'custom/Welcome' (language 'en')
[Jan 23 11:50:53] VERBOSE[3689] logger.c:   == Parsing '/etc/asterisk/manager.conf': [Jan 23 11:50:53] VERBOSE[3689] logger.c: Found
[Jan 23 11:50:53] VERBOSE[3689] logger.c:   == Parsing '/etc/asterisk/manager_additional.conf': [Jan 23 11:50:53] VERBOSE[3689] logger.c: Found
[Jan 23 11:50:53] VERBOSE[3689] logger.c:   == Parsing '/etc/asterisk/manager_custom.conf': [Jan 23 11:50:53] VERBOSE[3689] logger.c: Found
[Jan 23 11:50:53] VERBOSE[3689] logger.c:   == Manager 'admin' logged on from 127.0.0.1
[Jan 23 11:50:54] VERBOSE[3689] logger.c:   == Manager 'admin' logged off from 127.0.0.1
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Redirecting Zap/2-1 to fax extension
[Jan 23 11:50:54] VERBOSE[3687] logger.c:   == Spawn extension (ivr-3, fax, 0) exited non-zero on 'Zap/2-1'
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] Goto("Zap/2-1", "ext-fax|in_fax|1") in new stack
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Goto (ext-fax,in_fax,1)
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] StopPlayTones("Zap/2-1", "") in new stack
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] GotoIf("Zap/2-1", "1?3:analog_fax|1") in new stack
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Goto (ext-fax,in_fax,3)
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] Macro("Zap/2-1", "faxreceive") in new stack
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:1] Set("Zap/2-1", "FAXFILE=/var/spool/asterisk/fax/1232733050.0.tif") in new stack
[Jan 23 11:50:54] DEBUG[3687] app_macro.c: Executed application: Set
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:2] Set("Zap/2-1", "[email protected]") in new stack
[Jan 23 11:50:54] DEBUG[3687] app_macro.c: Executed application: Set
[Jan 23 11:50:54] VERBOSE[3687] logger.c:     -- Executing [[email protected]:3] RxFAX("Zap/2-1", "/var/spool/asterisk/fax/1232733050.0.tif") in new stack
[Jan 23 11:51:00] VERBOSE[3710] logger.c: Asterisk Event Logger Started /var/log/asterisk/event_log
[Jan 23 11:51:00] VERBOSE[3710] logger.c: Asterisk Dynamic Loader Starting:
[Jan 23 11:51:00] VERBOSE[3710] logger.c:   == Parsing '/etc/asterisk/modules.conf': [Jan 23 11:51:00] VERBOSE[3710] logger.c: Found
[Jan 23 11:51:00] VERBOSE[3710] logger.c:   == Parsing '/etc/asterisk/dnsmgr.conf': [Jan 23 11:51:00] VERBOSE[3710] logger.c: Found