Installing Hylafax

1) # apt-get install -y hylafax-server

2) # faxsetup

Simply press Enter after the following 2-3 questions. Specify serial port ttyIAX0 when it asks. Enter your area code and phone number afterward and everything after that can be left with the defaults. When you are asked if you would like to configure another modem, say no.

3) Create an IAX2 extension in FreePBX. Make sure to use the same port in the ttyIAX0 file you created earlier. Also, enter the following:

For each modem you create (iaxmodem), create it also in AvantFax. Modems can be mapped to users, which is what we will do now. Under the pull-down menu, select modems. Create the modem when you configured iaxmodem above.

Now, you need to create a new user:

Under the pull-down menu, select new user: create a user and make sure you map him/her to a modem like below;

IMPORTANT! – When you create a new user, there’s a “bug” in hylafax that you also need to manually do it over the cli. So in this case, I’ve created user sanjay and must delete this user and recreate via cli like below; YOU MUST FOLLOW THE ORDER IN WHICH IS SHOWN AFTER CREATING A USER IN AVANTFAX UI ABOVE.

# faxdeluser sanjay
# faxadduser sanjay

It should not have any other objects/characters after the @ for the newly created regular users! as seen corrected above by the faxadduser command.. Make sure the name you created in Avantfax is similar and unique and match that name with the faxadduser command.

Restart hylafax

# /etc/init.d/hylafax restart

Now, you should be able to send the fax in to this user/extension and log on to the WebUI or you can receive an fax-to-email email.

Here’s a test fax i just received without any modification to the graphics and what not:

To create more users:

1) Create a FreePBX extension like shown above (make sure you use unique port numbers, like 4801….4802….4803…etc)
2) Create an IAX modem (you can copy the ttyIAX0 config file to another file, say #cp ttyIAX0 ttyIAX1, modify that 1 file to match the FreePBX extension info you just created on FreePBX), follow the rest of the steps there to restart and create the inittab entry, like below (for ttyIAX1) : NOTICE the underlined values go up as we add new modems.