[asterisk-users] asterisk -C option not honored 100%

Tzafrir Cohen tzafrir.cohen at xorcom.com
Tue Apr 28 13:54:31 CDT 2009


On Tue, Apr 28, 2009 at 01:19:08PM -0500, David Siefert wrote:
> Hello,
> 
> I am trying to get a repeatable build setup for asterisk.  Part of doing 
> so involves using the -C option to specify the master config file.  The 
> problem is that asterisk reads the config file location that i specify, 
> however it still tries to read two other config files, namely:
> 
> * /etc/asterisk/extconfig.conf, and
> * /etc/asterisk/logger.conf
> 
> I have specified in my config file that the astetcpath maps to 
> ${ENV(PWD)}/dev/etc/asterisk.  Sounds like these two files might be 
> hard-coded paths in the distro?  Any way to fix this or work-around?
> 
> I am running Asterisk 1.4.21.2~dfsg-1ubuntu3 on Ubuntu 8.10.

That sounds odd.

I've just tested it with the package from Debian Lenny (which is
practically the sample package)

mkdir /tmp/asterisk
mkdir /tmp/asterisk/log
mkdir /tmp/asterisk/run
mkdir /tmp/asterisk/lib
mkdir /tmp/asterisk/mods
cp /etc/asterisk/logger.conf /etc/asterisk/extconfig.conf /tmp/asterisk
cat <<EOF >/tmp/asterisk/asterisk.conf
[directories]
astetcdir => /tmp/asterisk
astmoddir => /tmp/asterisk/mods
astvarlibdir => /tmp/asterisk/lib
astagidir => /usr/share/asterisk/agi-bin
astspooldir => /var/spool/asterisk
astrundir => /tmp/asterisk/run
astlogdir => /tmp/asterisk/log
EOF
chown -R asterisk /tmp/asterisk
asterisk -C /tmp/asterisk/asterisk.conf # -c , -r , -v, whatever

However I did notice that the package is shipped with a bogus
asterisk.conf that has [globals] instead of [directories] . Will be
fixed.

Anyway, please report bugs in packages to the packager (use reportbug).

-- 
               Tzafrir Cohen
icq#16849755              jabber:tzafrir.cohen at xorcom.com
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir



More information about the asterisk-users mailing list