Tutorial: Adding new outgoing service (trunk) in OwnPages using Asterisk GUI

After OwnPages is set-up, the Asterisk instance in the OwnPages server is started and you are ready to make outgoing calls. OwnPages provides you with default trunk (outgoing phone service) through which you can make your outgoing calls. This post shows how you can use Asterisk GUI to create a new trunk in OwnPages if you have another outgoing service provider or want to add a phone gateway.

CONTENT


1 Creating a new trunk.

2 Creating an Outgoing calling rule.

3 Adding calling rule in Dial plan.



1 Creating a new trunk.

Steps for creating new outgoing trunk.

Step 1:
Login into your admin email account, from within your LAN if using OwnPages onsite.
Goto Administer => PBX configuration => Advanced configuration.

Clicking on ‘Advanced configuration’ will take you to the Asterisk GUI.

Step 2:
Click on Trunks.
i.e Trunks => VOIP Trunks
It will show you available outgoing VOIP trunks.
Click on ‘create new Sip/Iax trunk’ to create new outgoing trunk. This is required even if you are setting up a phone gateway such as an Audiocodes box.



view image in another window


Step 3:
Clicking on ‘create new Sip trunk’ will force a pop-up window, there you will be required to enter the details of the username, password with which you will register to the outgoing trunk service provider along with the hostname of the trunk service provider.
Details are mentioned below.


view image in another window

  • Type : SIP
  • Context Naming: select ‘Based on username’ option.
  • Provider Name: Name the trunk anything you wish.
  • Hostname : IP/Address of the service provider.
  • Username : userid with which the OwnPages PBX will register with the service provider.

After entering the details save the settings and your outgoing trunk will be created.

You can see the trunk been created when you click on Trunks => VOIP Trunks.


view image in another window

2 Creating an Outgoing calling rule.

After the trunk has been created, tell OwnPages Asterisk when to route the outgoing calls through created trunk by creating an Outgoing calling rule.

view image in another window


Create a new Outgoing calling rules by clicking on New Calling Rule.
Goto ‘Outgoing calling Rules’ => ‘New Calling Rule’.


view image in another window


Details of the options mentioned above are as follows.
  • Calling Rule Name: Specify a name for this calling rule.
  • Pattern: It implies that the calling rule will be applied to any number dialed in the specified pattern.
Eg: In our current calling rule the pattern ‘_9X.’, it means that any number dialed with its first digit as 9 will be assigned this calling rule.
  • Since you are creating an outgoing calling rule, do not click on ‘Send to local destination’.
  • And then in ‘Send this call through trunk’ section, you need to make following entries.
1. Use trunk : select the trunk for this particular calling rule. The trunk which you created previously has to be selected.
2. Strip : Number of digits to be striped before passing it to the service provider.
Eg: If number dialed is 91600123456, then the first digit will be striped and will passed to the service provider as 1600123456.
  • Alternate trunk option lets you select the trunk the through which your outgoing calls will will be passed when this trunk is unable to make calls.
And after saving the calling rule it will appear in the list of calling rules.

view image in another window


3 Adding calling rule in Dial plan.

Now that the outgoing calling rule has been created it has to be added in the Dial plan.
Dial Plan is a set of Calling Rules.

view image in another window

Edit the existing dial plan to include the newly created outgoing calling rule.

You just have to tick the checkbox to include the new outgoing rule in the existing dialplan, and save the settings.

view image in another window


After all these steps are completed, click on Apply Changes to reload your sip configuration. If the trunk has been properly set-up and gets registered with the service provider then it will reflect in the 'System Status' in the list of registered Trunks.



In brief, adding a new trunk requires creating a new trunk and then creating an outgoing calling rule for it and including it in your existing dial plan.

Newer Post Older Post Home