Page 87 - Asterisk™: The Future of Telephony
P. 87
Directories Used by Asterisk
Asterisk uses several directories on a Linux system to manage the various aspects of the
system, such as voicemail recordings, voice prompts, and configuration files. This sec-
tion discusses the necessary directories, all of which are created during installation and
configured in the asterisk.conf file.
/etc/asterisk/
The /etc/asterisk/ directory contains the Asterisk configuration files. One file, however
—zaptel.conf—is located in the /etc/ directory. The Zaptel hardware was originally
designed by Jim Dixon of the Zapata Telephony Group as a way of bringing reasonable
and affordable computer telephony equipment to the world. Asterisk makes use of this
hardware, but any other software can also make use of the Zaptel hardware and drivers.
Consequently, the zaptel.conf configuration file is not directly located in
the /etc/asterisk/ directory.
/usr/lib/asterisk/modules/
The /usr/lib/asterisk/modules/ directory contains all of the Asterisk loadable modules.
Within this directory are the various applications, codecs, formats, and channels used
by Asterisk. By default, Asterisk loads all of these modules at startup. You can disable
any modules you are not using in the modules.conf file, but be aware that certain mod-
ules are required by Asterisk or are dependencies of other modules. Attempting to load
Asterisk without these modules will cause an error at startup.
/var/lib/asterisk
The /var/lib/asterisk/ directory contains the astdb file and a number of subdirectories.
The astdb file contains the local Asterisk database information, which is somewhat like
the Microsoft Windows Registry. The Asterisk database is a simple implementation
based on v1 of the Berkeley database. The db.c file in the Asterisk source states that this
version was chosen for the following reason: “DB3 implementation is released under
an alternative license incompatible with the GPL. Thus, in order to keep Asterisk li-
censing simplistic, it was decided to use version 1 as it is released under the BSD
license.”
The subdirectories within /var/lib/asterisk/ include:
agi-bin/
The agi-bin/ directory contains your custom scripts, which can interface with As-
terisk via the various built-in AGI applications. For more information about AGI,
see Chapter 8.
Directories Used by Asterisk | 59