So you can configure Asterisk and IAX2, Kinnekt natively supports the following IAX/IAX2 ‘Asterisk’ based IP-PBX implementations.

  • Asterisk 1.2/1.4/1.6, 1.8
  • Trixbox
  • FreePBX
  • Callweaver
  • Freeswitch etc.


General Comments


Registration only: For security reasons we restrict our IAX2 connectivity to Registration and therefore have not extended our support to Peering for IAX2. If you require the flexibility of Peering, you should consider changing to SIP Peering.


CLI: In order to preserve outgoing CLI we advise IAX2 admins to individually Register each DID as opposed to registering a primary trunk number.


TLS: Kinnekt supports TLS and TCP negating many of the previous technical advantages IAX had over over SIP.



How to configure IAX2 Registration


To customise your IAX2 Inbound context go to Kinnekt CloudPBX | Preferences | Voice Quality and Networking (specify your context for inbound calls)


IAX.jpg



Sample Configure


There’s no completely right or wrong way to configure your Asterisk server but the following provides a good template to start making calls through Kinnekt CloudPBX.

Using the example configuration below replace ‘yournumber’ with your actual Kinnekt CloudPBX number (e.g. 0289707504) and ‘yourpassword’ with your Kinnekt CloudPBX account password.

Kinnekt CloudPBX use the STD code+number format for usernames e.g. 0289707504 rather than the E164 version (61289707504) as some providers do.


sip.conf


[general]
registerattempts=0
registertimeout=20
; Register line should be somewhere inside your general section
register => yournumber:yourpassword@phone.kinnekt.com.au/yournumber


[Kinnekt]
type=friend
username=yournumber
fromuser=yournumber
secret=yourpassword
host=phone.kinnekt.com.au
context=default ; or your own selected context if desired
dtmfmode=rfc2833
disallow=all
allow=ilbc
allow=gsm
allow=alaw
allow=ulaw
;allow=g729 ; only if you have licenses to use it
nat=yes
canreinvite=no
insecure=very ; use insecure=invite,port in later versions of Asterisk such as v1.4
extensions.conf


[default]
;receive incoming calls to a connected phone
exten => s,1,Dial(SIP/yournumber)
; outbound calls (outside of your own PBX)
exten => _X.*,1,Dial(SIP/${EXTEN}@kinnekt)

 


Troubleshooting


In comparison to SIP, troubleshooting IAX2 is always problematic. If you do require assistance troubleshooting IAX calls, enabling IAX debugging output can be helpful.

  • Asterisk 1.4 or later, the CLI command ‘iax2 set debug on’ turns on debugging output.
  • Asterisk 1.2, use ‘iax2 debug’ to enable IAX debugging output, and ‘iax2 no debug’ to turn it back off again.
  • Send us the debug together with your Asterisks version.


IAX Context


IAX2 is different than SIP in that when you send a call to the other side you specify the ‘context’ you want the call to go to.

  • Outbound Calls: For calls to Kinnekt (from the customer) use the context ‘default’.
  • Inbound calls: For calls from Kinnekt to the customer we use the context ‘from-trunk’. This is historically how IAX2 was setup – the carrier side sends it ‘from-trunk’. It was also the default method used by FreePBX and other packaged Asterisk systems.