Hi Rand,
The default path to the asterisk.conf is /etc/asterisk and I believe that on
Optware has been patched to be /opt/etc/asterisk.
Also, you can specify the config file to be used in the command line using the
-C command line option:
http://www.voip-info.org/wiki/view/Asterisk+options
asterisk.conf will configure the directories used by asterisk (including the
directory for the config files).
For Optware the paths should be like this:
[directories]
astetcdir => /opt/etc/asterisk
astmoddir => /opt/lib/asterisk/modules
astvarlibdir => /opt/var/lib/asterisk
astagidir => /opt/var/lib/asterisk/agi-bin
astspooldir => /opt/var/spool/asterisk
astrundir => /opt/var/run
astlogdir => /opt/var/log/asterisk
Usually Asterisk comes with sample configuration files. You will have to write
your own configs, based on this samples.
Good luck,
Corneliu
--- In nslu2-asterisk@yahoogroups.com, "shermanrand" <shermanrand@...> wrote:
>
> Everyone,
>
> I recently loaded Asterisk on my WRT-54gl with 2gig sd. (did the ipkg, jffs,
optware etc...
>
> Although it runs - when is I issue $asterisk -cvvv I can see that it can't
quite find the config files. I guess that the init file needs to be modified
correctly. Here is some of the output of the errors.
> Otherwise, asterisk does come up with the >CLI command but no modules nor
configs are loaded - even though they are in their respective folders.
>
> typical - error is
> Parsing '/etc/asterisk/modules.conf' : Not found no such file or directories
......
>
> Here is the current init - which I think needs to be modified to direct the
program to the correct locations - but I don't know how to modify it. Can
someone tell me where in the init to direct the program to the correct
directories?
>
> Thanks Rand
>
>
>
>
> root@sherman:/jffs/etc/init.d# cat asterisk
> #!/bin/sh
> DEFAULT=/etc/default/asterisk
> OPTIONS=""
> [ -f $DEFAULT ] && . $DEFAULT
> [ "$ENABLE_ASTERISK" = "yes" ] || exit 0
> case $1 in
> start)
> [ -d /var/run ] || mkdir -p /var/run
> [ -d /var/log/asterisk ] || mkdir -p /var/log/asteri
sk
> [ -d /var/spool/asterisk ] || mkdir -p /var/spool/as
terisk
> /usr/sbin/asterisk $OPTIONS
> ;;
> stop)
> [ -f /var/run/asterisk.pid ] && kill $(cat /var/run/
asterisk.pid) >/dev/null 2>&1
> ;;
> *)
> echo "usage: $0 (start|stop)"
> exit 1
> esac
>
> exit $?
>