Asteriskv6

From SOWNWiki
Jump to: navigation, search

Asterisk v6 is a port of Asterisk designed to operate on IPv6 networks. The port is maintained by Viagénie. It is available for download from http://www.asteriskv6.org In order to make asterisk protocol independent several source code changes have been made but currently only the SIP channel has been ported.

Currently two versions of asterisk v6 are available asteriskv6-20070409 and asteriskv6-20080107 although limited documentation is available it seems that the former version is based on asterisk 1.4.x and the latter based on the currently beta asterisk 1.6.x. For the sown setup it is necessary to read configuration from a database using the asterisk realtime system. This requires the correct version of asterisk add-ons maintained by Digium.

Currently we are using asteriskv6-20080107 based on the new version of asterisk with the appropriate asterisk add-ons, namely asterisk-addons-1.6.0-beta2. During testing it was found that the 1.4.x version of asterisk v6 would not work with the database connection and therefore required the use of beta code.

Database Setup

In order to use the realtime database with asterisk v6 several changes had to be made to the table. Firstly the size of the IP address field had to be increased to accommodate IPv6 addresses. Secondly a new field not present in the 1.4.x version of asterisk now seems to be required. This “defaultuser” field was also added. The database table description can be found below

Field Type Null Key Default Extra
id int(11) NO PRI NULL auto_increment
name varchar(80) NO UNI
host varchar(31) NO
nat varchar(5) NO no
type enum('user','peer','friend') NO friend
accountcode varchar(20) YES NULL
callgroup varchar(10) YES NULL
callerid varchar(80) YES NULL
canreinvite char(3) YES yes
context varchar(80) YES NULL
dtmfmode varchar(7) YES NULL
insecure varchar(4) YES NULL
mailbox varchar(50) YES NULL
md5secret varchar(80) YES NULL
secret varchar(80) YES NULL
setvar varchar(100) YES NULL
disallow varchar(100) YES all
allow varchar(100) YES ilbc;gsm;ulaw;alaw
ipaddr varchar(40) YES NULL
port smallint(5) unsigned NO 0
regserver varchar(100) YES NULL
regseconds int(11) NO 0
username varchar(80) NO
defaultuser varchar(20) YES NULL

Useful Tools

IPv6 VOIP is rare and finding tools to help with deployment and testing can be difficult. The following sections contain a list of compatible tools found to work with our installation

Linphone

Linphone is a fully featured IPv6 capable VOIP soft phone that works under Linux (a Windows beta is in development). IPv6 support can be enabled by ticking the use IPv6 box in the Linphone preferences. Linphone is available as a Debian package. It was noticed that the version in the Ubuntu repositories was an old version (v1.7.1) whereas the latest Debian package available was v2.1.0.

SIPP

The SIP Performance tool is designed to stress test sip servers by initiating calls based on XML scripts. It is IPv6 capable and can be run on the command line, useful when you are operating on a machine without X. The following command can be used to start a basic IPv6 test, initiating 10 calls per second to the extension 1 on the machine with IPv6 address 2001:630:d0:f700::250

./sipp [2001:630:d0:f700::250] -sn uac -i [2001:630:d0:f700::250] -s 1 -d 1000 -mi [2001:630:d0:f700::250]

When connecting SIPP to asterisk a corresponding entry must be in sip.conf. An example entry can be found below, the host should be replaced with the IPv6 address of the machine the SIPP client is running on. Authentication is also possible but would require the use of a different SIPP profile

[test]
type=friend
context=testing
user=sipp
host=2001:630:d0:f700::127
canreinvite=no
disallow=all
allow=ulaw

Testing

In order to test the asteriskv6 installation several different scenarios need to be considered. In these initial tests, client were connected to the same SOWN node, although there is nothing to suggest that this would not work across the entire SOWN network.

asteriskv6test.png

IPv4 to IPv4 calls

Setup

This was tested with a call between the following VOIP clients:

  • SJphone build 1.65.377a on Windows XP SP2
  • XLite version 3.0 release 1011b build 39984 on Mac OS X 10.5.2

Results

The call was successful, with SIP re-invites causing the RTP streams to be sent directly between the two clients, after approximately 10 seconds.

IPv6 to IPv4 calls

Setup

This was tested with a call between the following VOIP clients:

  • Linphone 1.7.1 on Ubuntu 7.10 using gnome (IPv6)
  • SJphone build 1.65.377a on Windows XP SP2 (IPv4)

Results

The call was successful, with the RTP streams travelling via the server.

IPv4 to IPv6 calls

Setup

This was tested with a call between the following VOIP clients:

  • SJphone build 1.65.377a on Windows XP SP2 (IPv4)
  • Linphone 1.7.1 on Ubuntu 7.10 using gnome (IPv6)

Results

The call was successful, with the RTP streams travelling via the server.

IPv6 to IPv6 calls

Setup

This was tested with a call between the following VOIP clients:

  • Linphone 1.7.1 on Ubuntu 7.10 using gnome
  • Linphone 1.7.1 on Ubuntu 7.10 using kde-4

Results

The call was successful, with the RTP streams travelling via the server. There seems to be some issue with sending the SIP re-invites, which we are currently investigating.

Further investigation has shown that calls can switch randomly from via asterisk to direct even when a call is in progress. The reason for this is not currently known and is under investigation