TUTORIAL HylaFAX / AvantFax for PIAF! - Parts 1-4

well when i do a IAX2 show peers for any box I have setup it shows a invalid command



I am not sure how else to check. I am able to receive faxes most of the time. but it is concerning that it shows them as "Please Wait"
 
IAX2 show peers for any box I have setup it shows a invalid command

That is cause for concern.

For interest, this is how the system works.

  1. Avantfax talks to Hylafax.
  2. Hylafax talks to the IAXMODEM
  3. IAXMODEM talks to asterisk.
So it would appear that the issue lies between IAXModem and Hylafax.

Joe
 
where would I find a list of what files are for this in what order kind of thing so that I can troubleshoot??
 
Hi

The script is open for inspection, it's not compiled, and you could step through it to inspect that everything is as it should be.

Joe
 
well when i do a IAX2 show peers for any box I have setup it shows a invalid command



I am not sure how else to check. I am able to receive faxes most of the time. but it is concerning that it shows them as "Please Wait"

The iax2 should be lowercase.
Did you run the command faxmodem add after configuring. Anyhow the please wait just means that avantfax isn't getting the info but it usally works. You could type faxstat -a for the same info
 
Can you ping localhost. If not, check your hosts file.

Joe
 
Hi! I have just installed a fresh copy of avantfax and everything look to work fine except for 1 thing, fax i receive are never put into the avantfax interface, it seems that avantfax isn't able to convert the tiff to PDF here is the log.

Code:
2009-10-01 22:34:55send_mail> 'fax: 329 01.10.2009 22:34' sent to '[email protected]' from 'root@localhost' - ()
2009-10-01 22:34:55notify> FAILED to create PDF for Archive2009-10-01 22:34:55convert2pdf> failed to create /var/www/html/avantfax/faxes/sent/2009/10/01/329/223455/fax.pdf2009-10-01 22:34:55mkdirs> Error creating directory /var/www/html/avantfax/faxes/sent/2009
2009-10-01 22:34:55notify> Executing: doneq/q8 done 0:33 (4)2009-10-01 22:34:54faxrcvd> Failed to copy recvq/fax000000007.tif to /var/www/html/avantfax/faxes/recvd/2009/10/01/18197802938/000000007/fax.tif
2009-10-01 22:34:54mkdirs> Error creating directory /var/www/html/avantfax/faxes/recvd/2009
2009-10-01 22:34:54faxrcvd> PROCESSING FAX from '+18197802938' (1 pages) received '2009:10:01 22:34:43'
2009-10-01 22:34:54faxrcvd> executing: recvq/fax000000007.tif ttyIAX0 '000000017' '' CIDNum: '+18197802938' CIDName: 'Martin Chicoine' DID: ''
2009-10-01 22:34:31dynconf> checking CallID1 +18197802938 on device /dev/ttyIAX0
 
when i do a ping localhost
i get ....

ping: unknown localhost


here is what my hosts file looks like


# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 myFQDN.dydns.net pbx.local pbx localhost.localdom$

;127.0.0.1 pbx.dyndns.org pbx.local pbx localhost.localdomain loca$

::1 localhost6.localdomain6 localhost6
 
FIXED:

for some reason when i have my FQDN in the hosts file then I can no longer make calls to my main DIDFORSALE number... very odd that this is happening............. once i leave the default value in there then everything is fine....
 
NOOB alert - only 2 DID's, what to do?

Hi, been following this thread for a while trying to get my implementation working. Finally solved my iaxmodem issues tonight and realized that I'm probably trying to do something that's not kosher.

I only have 2 analog trunks coming to my two line FXO digium card. What I would like to happen, and I can adjust my way of doing things, is to use both lines for voice, and have it detect whether the call is a FAX, or voice.

Right now, I have a day/night function.

day= 4-5 rings (all phones), then IVR
night= IVR

Is there a way to add possibly a pickup/check for fax, then ring phones then IVR for day, and pickup/check for fax, then IVR for night?

Thanks in advance for any help on this, and keep up the good work,

Michael
 
i was able to remove hylafax and now the modems are starting corectly... however, i have an issue with avantfax. i think this is because it was installed too many times...
please see attachement.
This happens when your MySQL database "avantfax" -> Table "Modems" is filled with duplicate.
 
:iagree: And usualy it comes from running some or all of the installation more than once.
 
Does this works with DAHDI? - No local dialtone problem

My System
  • CentOS 5.3
  • PBX in a Flash Version 1.4
  • Asterisk 1.4.26.2
  • Dahdi 2.2.0.2+2.2.0
  • Libpri 1.4.10.1

Problem
I followed this wonderful tutorial and all was working very well. I was able to fax-out using sendfax command as well as using Avantfax. I was also able to receive faxes successfully.

Today, I decided to update-source and upgrade to DAHDI instead of Zaptel (because I am having an unrelated bug with Zaptel that DAHDI fixes).

Since I've updated my PBX to DAHDI, hylafax always returns "No local dialtone" error messages.

/var/spool/hylafax/log
Code:
Oct 17 10:49:48.97: [ 3835]: SESSION BEGIN 000000068 14150000000
Oct 17 10:49:48.97: [ 3835]: HylaFAX (tm) Version 4.4.4
Oct 17 10:49:48.97: [ 3835]: SEND FAX: JOB 24 DEST 14150000000 COMMID 000000068 DEVICE '/dev/ttyIAX3' FROM 'root <[email protected]>' USER root
Oct 17 10:49:48.97: [ 3835]: STATE CHANGE: RUNNING -> SENDING
Oct 17 10:49:48.97: [ 3835]: <-- [12:AT+FCLASS=1\r]
Oct 17 10:49:48.97: [ 3835]: --> [2:OK]
Oct 17 10:49:48.97: [ 3835]: MODEM set XON/XOFF/FLUSH: input ignored, output disabled
Oct 17 10:49:48.97: [ 3835]: DIAL 14150000000
Oct 17 10:49:48.97: [ 3835]: <-- [16:ATDT14150000000\r]
Oct 17 10:49:48.97: [ 3835]: --> [11:NO DIALTONE]
Oct 17 10:49:48.97: [ 3835]: SEND FAILED: JOB 24 DEST 14150000000 ERR [4] No local dialtone
Oct 17 10:49:48.97: [ 3835]: SEND FAILED: JOB 24 DEST 14150000000 ERR [333] No local dialtone; too many attempts to dial
Oct 17 10:49:49.99: [ 3835]: <-- [5:ATH0\r]
Oct 17 10:49:49.99: [ 3835]: --> [2:OK]
Oct 17 10:49:49.99: [ 3835]: MODEM set DTR OFF
Oct 17 10:49:49.99: [ 3835]: MODEM set baud rate: 0 baud (flow control unchanged)
Oct 17 10:49:49.99: [ 3835]: STATE CHANGE: SENDING -> MODEMWAIT (timeout 5)
Oct 17 10:49:49.99: [ 3835]: SESSION END

faxstat -v
Code:
Trying localhost (127.0.0.1) at port 4559...
Connected to pbx.local.
220 my-pbx.com server (HylaFAX (tm) Version 4.4.4) ready.
-> USER root
230 User root logged in.
-> PORT 127,0,0,1,184,215
200 PORT command successful.
-> LIST status
150 Opening new data connection for "status".
HylaFAX scheduler on my-pbx.com: Running
Modem ttyIAX1 (0000000000): Running and idle
Modem ttyIAX4 (14150000000): Running and idle
Modem ttyIAX2 (0000000000): Running and idle
Modem ttyIAX3 (0000000000): Running and idle
Modem ttyIAX0 (0000000000): Running and idle
226 Transfer complete.

faxstat -s
Code:
HylaFAX scheduler on my-pbx.com: Running
Modem ttyIAX1 (0000000000): Running and idle
Modem ttyIAX4 (14150000000): Running and idle
Modem ttyIAX2 (0000000000): Running and idle
Modem ttyIAX3 (0000000000): Running and idle
Modem ttyIAX0 (0000000000): Running and idle

JID   S           Owner                       MailAddr Number          Pages Dials Prior     TTS Status
25    S            root       [email protected] 14150000000      0:1   1:12   126   10:39 No local dialtone

iax2 show peers
Code:
Name/Username    Host                 Mask             Port          Status    
2000             127.0.0.1       (S)  255.255.255.255  4574          OK (3 ms) 
iax-fax4         127.0.0.1       (S)  255.255.255.255  4574          OK (2 ms) 
iax-fax3         127.0.0.1       (S)  255.255.255.255  4573          OK (1 ms) 
iax-fax2         127.0.0.1       (S)  255.255.255.255  4572          OK (3 ms) 
iax-fax1         127.0.0.1       (S)  255.255.255.255  4571          OK (2 ms) 
iax-fax0         127.0.0.1       (S)  255.255.255.255  4570          OK (2 ms) 
6 iax2 peers [6 online, 0 offline, 0 unmonitored]

Like I said, everything was working fine until I update-source (chose DAHDI), update-scripts and update-fixes. When watching *CLI there is nothing showing up about the modem trying to dial or anything - nada.

If anyone could help shed some light on our problem it would be great. Also I would like to thank tshif for his great tutorials - you rock!

EDIT: I have not tested if we can receive faxes yet, but if I dial our DID number - the modem answers the call and I can hear the iaxmodem trying to negotiate a bitrate with my left ear ;-)
 
I ran more test and I conclude that iaxmodem/hylafax does not work with DAHDI for fax-out with this tutorial.

I reverted back to an image snapshot before I ran update-source w/ DAHDI and everything works fine. I then ran update-source again but without DAHDI and it works fine.

I started from scratch and install a fresh piaf from the .iso and went with DAHDI before installing iaxmodem/hylafx and it doesn't work to fax-out. The error message is "no local dialtone" which means that the modem can't connect with asterisk.

The *CLI doesn't report anything, I don't see any attempt to connect to asterisk from the modems - but they show as connected when I list "iax2 show peers".

I really need DAHDI because of a bug it fixes... I wish you guys have a way to make it work - anyone's got this working with DAHDI?
 
Are you also using iaxmodem to fax out? I'm doing a ks16 install from the .iso now to see if it works for me with Asterisk 1.6 - fingers crossed. Will report my findings later.

Okay - it's working with Asterisk 1.6 DAHDI and iaxmodem/hylafx/avantfax

I'm now trying to figure out why it won't work on my Asterisk 1.4 box with DAHDI.
 
Any successful PRI users out there?

Just wondering if any one out there is using this method successfully with PRI's for PSTN connectivity.

If so I'd love to hear from you. How many IAX modems do you have setup how many dedicated DID's for faxing are you using etc....

I'm evaluating which direction to go here.....
We are considering using this method or possibly trying to get RxFax to work by compiling SPANDSP. Looks like it involves some work either way.
 
So I followed the instructions and I can receive faxes just fine. However, when I try and send faxes, it seems to hangup as soon as the receiving end answers. Here is the relevant log output from asterisk:

-- Called cbeyond/5551212
-- SIP/cbeyond-09d70a60 is ringing
-- SIP/cbeyond-09d70a60 answered IAX2/iax-fax1-12592
== Spawn extension (macro-dialout-trunk, s, 19) exited non-zero on 'IAX2/iax-fax1-12592' in macro 'dialout-trunk'
== Spawn extension (macro-dialout-trunk, s, 19) exited non-zero on 'IAX2/iax-fax1-12592'
-- Executing [h@macro-dialout-trunk:1] Macro("IAX2/iax-fax1-12592", "hangupcall|") in new stack
-- Executing [s@macro-hangupcall:1] GotoIf("IAX2/iax-fax1-12592", "1?skiprg") in new stack
-- Goto (macro-hangupcall,s,4)
-- Executing [s@macro-hangupcall:4] GotoIf("IAX2/iax-fax1-12592", "1?skipblkvm") in new stack
-- Goto (macro-hangupcall,s,7)
-- Executing [s@macro-hangupcall:7] GotoIf("IAX2/iax-fax1-12592", "1?theend") in new stack
-- Goto (macro-hangupcall,s,9)
-- Executing [s@macro-hangupcall:9] Hangup("IAX2/iax-fax1-12592", "") in new stack
== Spawn extension (macro-hangupcall, s, 9) exited non-zero on 'IAX2/iax-fax1-12592' in macro 'hangupcall'
== Spawn extension (macro-hangupcall, s, 9) exited non-zero on 'IAX2/iax-fax1-12592'
-- Hungup 'IAX2/iax-fax1-12592'

Any thoughts?
 

Members online

No members online now.

Forum statistics

Threads
26,696
Messages
174,453
Members
20,265
Latest member
irenelanda64
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Back
Top