FreePBX Installation and Configuration

The modest hardware requirements, rock-solid stability, and extensive feature set of the FreePBX Open Source project make it the most cost-effective PBX platform for both Small and Midsize Enterprises.

Other than your up-front server hardware and telephony-card purchases, there are no out-of-pocket expenses for licensing or support to worry about. Yes, there are commercial modules available for purchase but there aren’t any that offer features I find justify paying for.

Overview

This post will provide information on how to get your FreePBX 2.11 server up and running with basic features. It will also explain how to add a streaming Music on Hold channel.

Hardware

Server hardware requirements aren’t exactly specified anywhere but there really isn’t a need for high-end CPU’s, RAID cards, “enterprise” level disk drives, or massive amounts of memory.

We’re running a modestly-used FreePBX installation for 50 users on a SuperMicro SuperServer 5017C MTF with 32GB of RAM and 50GB Solid-state drive.

We also purchased a Digium TE121B Digital PCI Card to use with an AT&T T1 BRI circuit.

Installation and Module Updates

Instructions on downloading and installing the FreePBX Distro can be found here:

http://www.freepbx.org/support/documentation/installation/installing-the-freepbx-distro

Download the ISO, burn it to a DVD, then use it to load the OS and FreePBX onto your server. Configure basic network services and verify that your server is available from another workstation.

Next, point a web browser at the host name or IP address of your server and login to the FreePBX Administrator GUI.

Click on the Admin menu and select Module Admin. You can now update your installation and install any additional modules you’re interested in. “Follow Me” and “Bulk Extensions” are definitely recommended.

Module Administration Screenshot

PBX_Module_Admin_Screenshot

DAHDi Configuration

Select DAHDi from the Connectivity menu and click the Edit link.

DAHDi Screenshot

DAHDI_Config

Note: There is a small Settings menu at the right side of the screen. I suggest using defaults for the settings in each of the sub menus unless you know what you’re doing.

The settings below are for an AT&T T1 BRI circuit. Your settings of course could be different so check with your provider.

DAHDi General Settings Screenshot

DAHDi_Gen_Settings

Save your settings.

Add a Trunk

Now that our signalling is configured we can configure a Trunk to use for outbound calls.

Go back to the Connectivity menu, select Trunk, then click Add DAHDi Trunk.

Add_Trunk

I am just using a single trunk so my settings are in the screen shot below. Please note that the Outbound Caller ID field can be overwritten by the settings assigned to your individual extensions.

DAHDi Trunk Screenshot

DAHDI_Channel_g0

Submit your changes.

Outbound Routes

Now we can create Outbound Routes that will use the DAHDi Trunk. I am using four routes to cover all possible outbound calls.

Dial patterns are built using the following rules:

X:  matches any number
Z:  matches the numbers 1-9 only
N: matches the numbers 2-9 only
.  : matches any symbol or digit repeatedly (wildcard)
| : when the bar is used, any digits to the left of it will be stripped before passing the call to the trunk
[ ]: use brackets to specify exact matches for more than one digit

If you have a second company site you can create an outbound route to allow “extension dialing” between the sites.

Emergency Dialing Outbound Route

Our employees can just dial “911”, but if your users need to dial “9” for an outside line you would use “9|911”

Trunk_911

Local Services Outbound Route

411, 511, etc…

Trunk_Local_Services

Local Calls Outbound Route

For any 7 digit calls that don’t begin with a 1

Trunk_Local_7

Long Distance Outbound Route

The dial plans allow users to dial domestic and international long distance with no restrictions and without having to dial “9” first.

Trunk_Long_Distance

Extensions

I’ll step you through the process of manually adding an extension that can be used with a Cisco, Polycom, or soft phone.

Bellow are the settings I use for adding a new extension.

Details:

  • The extensions you use will vary depending upon the size of your DID block and dial plans
  • The CID field will overwrite the Caller ID we configured for the DAHDi Trunk
  • Voice mail is enabled here with messages being sent as email attachments

Extensions_01

Extensions_02

Extensions_03

Bulk Extensions

Depending upon the number of users you are adding, you may want to use the “Bulk Extensions” module for this task.

If that is the route you are going to go, you will still want to manually create one extension first, export it, then use it as a template for adding your other users. Unfortunately I found myself still having to go and manually set voice mail settings because Bulk Extensions didn’t do it correctly.

Inbound Routes

If you added Inbound DID as shown above when configuring your extension then an Inbound Route was automatically created and your inbound calls for that extension will route appropriately. I didn’t set a DID Description in the example above, but if I wanted to I could go in and add it now.

Other items you can set here include:

  • Ring Tone: This is called “Alert Info” in FreePBX. Manually enter the name of a ring tone that your phone will understand. In the example below I am using the Pulse ring tone for a Cisco 504G phone.
  • Music On Hold: See the next section for details on configuring a Music on Hold alternative for your callers.
  • CallerID Lookup: I tried setting this up with one of the free services (OpenCNAM) and it just didn’t work properly. If it’s important you may want to pay for this service.

Inbound Route Screenshot

Inbound_Route

Music on Hold

The default FreePBX hold music is pretty awful so I suggest setting up an alternative for your callers. We dig SomaFM at my company, so I decided to stream them for our callers.

Here’s how I did it:

1. Add CentOS repositories to yum (from CLI)

My PBX server uses the repos listed below (look online if you don’t know how to do this):

centos-asterisk-11.repo
centos-asterisk-1.8.repo
CentOS-Base.repo
centos-digium-11.repo
centos-digium-1.8.repo
CentOS-Media.repo
centos-asterisk-1.8-certified.repo
centos-asterisk.repo
CentOS-Debuginfo.repo
centos-digium-1.8-certified.repo
centos-digium.repo
CentOS-Vault.repo
2. Install gcc and make

[root@pbx ~]# yum install gcc make

3. Download mpg123 from SourceForge and install it
[root@pbx src]# wget http://sourceforge.net/projects/mpg123/files/mpg123/1.13.4/mpg123-1.13.4.tar.bz2/download
[root@pbx src]# tar -xjvf mpg123-1.13.4.tar.bz2
[root@pbx src]# cd mpg123-1.13.4
[root@pbx mpg123-1.13.4]# ./configure
[root@pbx mpg123-1.13.4]# make
[root@pbx mpg123-1.13.4]# make install

4. Configure new Streaming Category

Go to the Settings menu and select Music On Hold. Add a new Streaming Category and configure similar to the screenshot below

MOH

5. Apply to Inbound Routes

This was covered earlier in the post.

4 comments

  1. Que tal mi Buena Amigo, es un muy buen articulo el que presentas… Recién he empezado a trabajar con esto de Telefonía sobre internet y apenas estoy aprendiendo algo acerca de esto…. Ahora me gustaría me pudieras ayudar con algunos problemas que tengo acerca de las rutas d entrada, pues no me permite recibir llamadas ni reedireccionarlas¡?¡’ he hecho lo que has mostrado en tu articulo pero me falla algo y no se que pueda ser uso una tarjeta Digium td410.. Espero me puedas ayudar Te lo agradecería mucho.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s