System information

You do not appear to have the sources for the 2.6.18-164.6.1.el5 kernel
installed.
You will get this error when attempting to build DAHDI without having installed the
Linux headers, which are required for building Linux drivers.
Ubuntu CentOS
$ sudo apt-get install linux-headers-`uname -r` $ sudo yum install kernel-devel
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
If you encounter this error it’s likely that you forgot to prepend sudo to the start of the
command you were running, which requires root permissions.
Upgrading Asterisk
Upgrading Asterisk between major versions, such as from 1.2 to 1.4 or from 1.6.2 to
1.8 is akin to upgrading an operating system. Once a phone switch is in production, it
is terribly disruptive for that system to be unavailable for nearly any length of time, and
the upgrade of that phone system needs to be well thought-out, planned, and tested as
much as possible prior to deployment. And because every deployment is different, it is
difficult, if not impossible, for us to walk you through a real system upgrade. However,
we can certainly point you in the right direction for the information you require in order
to perform such an upgrade, thereby giving you the tools you need to be successful.
A production Asterisk system should never be upgraded between major versions with-
out first deploying it into a development environment where the existing configuration
files can be tested and reviewed against new features and syntax changes between ver-
sions. For example, it may be that your dialplan relies on a deprecated command and
should be updated to use a new command that contains more functionality, has a better
code base, and will be updated on a more regular basis. Commands that are deprecated
are typically left in the code for backward-compatibility, but issues reported about these
deprecated commands will be given lower priority than issues to do with the newer
preferred methods.
There exist two files that should be read prior to any system upgrade: CHANGES and
UPGRADE.txt, which are shipped with the Asterisk source code. These files contain
details on changes to syntax and other things to be aware of when upgrading between
major versions. The files are broken into different sections that reference things such
as dialplan syntax changes, channel driver syntax changes, functionality changes, and
deprecation of functionality, with suggestions that you update your configuration files
to use the new methods.
68 | Chapter 3:Installing Asterisk