(closes issue #7852)
[asterisk/asterisk.git] / doc / tex / asterisk-conf.tex
1 \subsubsection{Asterisk Main Configuration File}
2
3 Below is a sample of the main Asterisk configuration file,
4 asterisk.conf. Note that this file is not provided in
5 sample form, because the Makefile creates it when needed
6 and does not touch it when it already exists.
7
8 \begin{astlisting}
9 \begin{verbatim}
10 [directories]
11 ; Make sure these directories have the right permissions if not
12 ; running Asterisk as root 
13
14 ; Where the configuration files (except for this one) are located
15 astetcdir => /etc/asterisk
16
17 ; Where the Asterisk loadable modules are located
18 astmoddir => /usr/lib/asterisk/modules
19
20 ; Where additional 'library' elements (scripts, etc.) are located
21 astvarlibdir => /var/lib/asterisk
22
23 ; Where AGI scripts/programs are located
24 astagidir => /var/lib/asterisk/agi-bin
25
26 ; Where spool directories are located
27 ; Voicemail, monitor, dictation and other apps will create files here
28 ; and outgoing call files (used with pbx_spool) must be placed here
29 astspooldir => /var/spool/asterisk
30
31 ; Where the Asterisk process ID (pid) file should be created
32 astrundir => /var/run/asterisk
33
34 ; Where the Asterisk log files should be created
35 astlogdir => /var/log/asterisk
36
37
38 [options]
39 ;Under "options" you can enter configuration options
40 ;that you also can set with command line options
41
42 ; Verbosity level for logging (-v)
43 verbose = 0
44
45 ; Debug: "No" or value (1-4)
46 debug = 3                                       
47
48 ; Background execution disabled (-f)
49 nofork=yes | no                                 
50
51 ; Always background, even with -v or -d (-F)
52 alwaysfork=yes | no
53
54 ; Console mode (-c)
55 console= yes | no
56
57 ; Execute with high priority (-p)
58 highpriority = yes | no
59
60 ; Initialize crypto at startup (-i)
61 initcrypto = yes | no
62
63 ; Disable ANSI colors (-n)
64 nocolor = yes | no
65
66 ; Dump core on failure (-g)
67 dumpcore = yes | no
68
69 ; Run quietly (-q)
70 quiet = yes | no
71
72 ; Force timestamping in CLI verbose output (-T)
73 timestamp = yes | no
74
75 ; User to run asterisk as (-U) NOTE: will require changes to
76 ; directory and device permissions
77 runuser = asterisk                              
78
79 ; Group to run asterisk as (-G)
80 rungroup = asterisk
81
82 ; Enable internal timing support (-I)
83 internal_timing = yes | no
84
85 ; These options have no command line equivalent
86
87 ; Cache record() files in another directory until completion
88 cache_record_files = yes | no                   
89 record_cache_dir = <dir>
90
91 ; Build transcode paths via SLINEAR
92 transcode_via_sln = yes | no                    
93
94 ; send SLINEAR silence while channel is being recorded
95 transmit_silence_during_record = yes | no
96
97 ; The maximum load average we accept calls for
98 maxload = 1.0
99
100 ; The maximum number of concurrent calls you want to allow
101 maxcalls = 255 
102
103 ; Stop accepting calls when free memory falls below this amount specified in MB
104 minmemfree = 256
105
106 ; Allow #exec entries in configuration files
107 execincludes = yes | no
108
109 ; Don't over-inform the Asterisk sysadm, he's a guru
110 dontwarn = yes | no
111
112 ; System name. Used to prefix CDR uniqueid and to fill \${SYSTEMNAME}
113 systemname = <a_string>
114
115 ; Should language code be last component of sound file name or first?
116 ; when off, sound files are searched as <path>/<lang>/<file>
117 ; when on, sound files are search as <lang>/<path>/<file>
118 ; (only affects relative paths for sound files)
119 languageprefix = yes | no                       
120
121 ; Locking mode for voicemail
122 ;  - lockfile: default, for normal use
123 ;  - flock: for where the lockfile locking method doesn't work
124 ;           eh. on SMB/CIFS mounts
125 lockmode = lockfile | flock
126   
127
128 [files]
129 ; Changing the following lines may compromise your security
130 ; Asterisk.ctl is the pipe that is used to connect the remote CLI
131 ; (asterisk -r) to Asterisk. Changing these settings change the
132 ; permissions and ownership of this file. 
133 ; The file is created when Asterisk starts, in the "astrundir" above.
134
135 ;astctlpermissions = 0660
136 ;astctlowner = root
137 ;astctlgroup = asterisk
138 ;astctl = asterisk.ctl
139
140 \end{verbatim}
141 \end{astlisting}