[Asterisk-Dev] Multi asterisk installation
Steve Kann
stevek at stevek.com
Tue May 3 09:21:13 MST 2005
Tzafrir Cohen wrote:
>On Tue, May 03, 2005 at 04:30:07PM +0200, Marcin Pietrzyk wrote:
>
>
>>On 03/05/2005 at 13:18 Tzafrir Cohen wrote:
>>
>>
>>
>>>Just give each Asterisk instance its own directory.
>>>
>>>If you want to run it as non-root, you'd probably want to create the pid
>>>file and the socket in a separate subdirectory under /var/run .
>>>
>>>Here is asterisk.conf from debian:
>>>
>>>[global]
>>> astetcdir => /etc/asterisk
>>> astmoddir => /usr/lib/asterisk/modules
>>> astvarlibdir => /var/lib/asterisk
>>> ; in debian software lives under /usr
>>> astagidir => /usr/share/asterisk/agi-bin
>>> astspooldir => /var/spool/asterisk
>>> astrundir => /var/run/asterisk
>>> astlogdir => /var/log/asterisk
>>>
>>>Replace each /asterisk$ in that file with a custom directory for your
>>>instance, owned by the user of that instance.
>>>
>>>
>>Ok. right i will test this solution, and report is it working. Have
>>anyone tried this ? Or tried to :-)
>>
>>But still even if its working this solution leads to having 2
>>instalation of asterisk in different directories, any ideas of running
>>two times the same asterisk with two different configs ?
>>
>>
>
>You can use a single asterisk binary, modules (and agi directory, if you
>so wish).
>
>Run those asterisk instances as two different users, and not as root.
>Don't chmod 666 or 777.
>That way you'll immediately get permission errors about any problem, and
>you'll be sure that those two copies don't run over one-another's data.
>
>
You can run lots of separate asterisk processes on a single box; with
each restricted to it's own configs, it's own IP to bind to, etc. I do
this all the time.
-SteveK
More information about the asterisk-dev
mailing list