Problem during installation of FreePBX 2.2.1

Hi,

i tried to install freepbx-2.2.1 with this documentation: http://www.aussievoip.com/wiki/freePBX-Ubuntu. i use asterisk 1.2.14 with bristuff-0.3.0 on a ubuntu 6.10 machine. all works fine, but during the last steps of the installation some problems are appearing:

[code:1]
[email protected]:/usr/src/freepbx-2.2.1# ./install_amp
Checking for PEAR DB…OK
Checking for PEAR Console::Getopt…OK
Checking user…OK
Checking for /etc/amportal.conf…OK
Reading /etc/amportal.conf…OK
Checking for /etc/asterisk/asterisk.conf…OK
Reading /etc/asterisk/asterisk.conf…OK
Using asterisk as PBX Engine
Checking for Asterisk 1.2…OK
Checking for selinux…OK
Connecting to database…OK
Checking current version of AMP…2.2.1
Installing new AMP files…OK
Configuring install for your environment…OK
Setting permissions on files…OK
Checking for upgrades…0 found
Generating AMP configs…
Generating Configurations.conf…
-su: /var/lib/asterisk/bin/retrieve_conf: Permission denied
Generating AMP configs…OK
Restarting Flash Operator Panel…-su: /var/www/admin/bounce_op.sh: Permission denied
OK
Please update your modules and reload Asterisk by visiting http://192.168.178.100/admin


  • Note: It’s possible that if you click the red ‘Update Now’ bar BEFORE *
  • updating your modules, your machine will start dropping calls. Ensure *
  • that all modules are up to date BEFORE YOU CLICK THE RED BAR. As long *
  • as this is observed, your machine will be fully functional whilst the *
  • upgrade is in progress. *

[email protected]:/usr/src/freepbx-2.2.1#
[/code:1]

at my browser i get this message while accessing my local-adress:

[code:1]
Warning: file(/etc/amportal.conf) [function.file]: failed to open stream: Permission denied in /var/www/admin/functions.inc.php on line 35
Missing or unreadable config file (/etc/amportal.conf)…cannot continue
[/code:1]

i hope some of u get some hints

regards
fruitz

[quote]STARTING ASTERISK
/usr/sbin/safe_asterisk: 93: Syntax error: Bad fd number
Asterisk Started[/quote]
safe_asterisk is part of asterisk - it appears your shell doesn’t like something in that script?

Hi again,

i think i found a solution.
after reinstall my system, i managed to run asterisk as non-root user with this documentation:
http://www.voip-info.org/wiki/index.php?page=Asterisk+non-root

“./install_amp” works fine:

[code:1]Checking for PEAR DB…OK
Checking for PEAR Console::Getopt…OK
Checking user…OK
Checking for /etc/amportal.conf…OK
Reading /etc/amportal.conf…OK
Checking for /etc/asterisk/asterisk.conf…OK
Reading /etc/asterisk/asterisk.conf…OK
Using asterisk as PBX Engine
Checking for Asterisk 1.2…OK
Checking for selinux…OK
Connecting to database…OK
Checking current version of AMP…2.2.1
Installing new AMP files…OK
Configuring install for your environment…OK
Setting permissions on files…OK
Checking for upgrades…0 found
Generating AMP configs…
Generating Configurations.conf…
Generating AMP configs…OK
Restarting Flash Operator Panel…OK
Please update your modules and reload Asterisk by visiting http://192.168.178.100/admin


  • Note: It’s possible that if you click the red ‘Update Now’ bar BEFORE *
  • updating your modules, your machine will start dropping calls. Ensure *
  • that all modules are up to date BEFORE YOU CLICK THE RED BAR. As long *
  • as this is observed, your machine will be fully functional whilst the *
  • upgrade is in progress. *

[email protected]:/usr/src/freepbx-2.2.1#
[/code:1]

After that a new problem is occurred:

[code:1]
[email protected]:/usr/src/freepbx-2.2.1# modprobe ztdummy
[email protected]:/usr/src/freepbx-2.2.1# amportal start

SETTING FILE PERMISSIONS
Permissions OK

STARTING ASTERISK
/usr/sbin/safe_asterisk: 93: Syntax error: Bad fd number
Asterisk Started

STARTING FOP SERVER
FOP Server Started
[email protected]:/usr/src/freepbx-2.2.1#
[/code:1]

What does this error means?

greets
fruitz

sorry, I don’t run with Ubuntu - if you can’t get it going with the instructions, try getting onto #freepbx (IRC) and try to find someone who can help you.

hi,

i just tested

[code:1]vn co https://svn.sourceforge.net/svnroot/amportal/freepbx/branches/2.2 freepbx-2.2 [/code:1]
the same errors are appearing. my amportal.conf is in the correct path (/etc/amportal.conf).
But another question: How to run asterisk as user asterisk? i tried [code:1]asterisk -U asterisk
Unable to open pid file ´var/run/asterisk.pid´: Permission denied
[/code:1]
…but a file called “asterisk.pid” does not exist on my system.

Greets
Fruitz

looks like a series of permission problems. Make sure that asterisk and apache run as user asterisk, and that all files are owned by asterisk. And amportal.conf needs to be in /etc. Also note - there are a series of hardcoded paths for some of the standard directories that are not all fixed in the code. More are fixed in 2.2 svn but I’m sure there are more that have not been addressed in some of the modules.