System information
The Asterisk CLI
The best way to see what is happening with your Asterisk system is through the Asterisk
CLI. This interface provides various levels of output to let you know what is happening
on your system, and offers a wealth of useful utilities to allow you to affect your running
system. Begin by calling up the Asterisk CLI and reloading the configuration files for
your channel modules:
$ sudo asterisk -r
*CLI> module reload chan_sip.so
*CLI> module reload chan_iax2.so
Verify that your new channels have been loaded:
*CLI> sip show peers
*CLI> sip show users
*CLI> iax2 show peers
*CLI> iax2 show users
At this point your Asterisk system should be configured to handle reg-
istrations from
the defined devices. Calls to and from the sets will not
work until the configuration on the devices has been completed. Since
each device is different in this regard, detailed configuration instructions
for each model are outside of the scope of this book.
Testing to Ensure Your Devices Have Registered
Once your device has registered to Asterisk, you will be able to query the location and
state of the device from the Asterisk CLI.
It is a common misconception that registration is how a device authen-
ticates
itself for the purpose of obtaining permission to make calls. This
is incorrect. The only purpose of registration is to allow a device to
identify its location on the network, so that Asterisk
#
knows where to
send calls intended for that device.
Authentication for outgoing calls is an entirely separate process and al-
ways happens on a per-call basis, regardless of whether a set has regis-
tered. This means that your set may be able to make calls, but not receive
them. This will normally happen when the set has not registered suc-
cessfully (so Asterisk does not know where it is), and yet has the correct
credentials for making calls (so Asterisk is willing to accept calls from it).
To check the registration status of a device, simply call up the Asterisk CLI:
$ sudo asterisk -r
#Or any other SIP registrar server, for that matter.
Testing to Ensure Your Devices Have Registered | 99
Downloa d f r o m W o w ! e B o o k < w w w.woweb o o k . c o m >