Asterisk +m Freepbx = no freepbx modules. (Hangs with the orange box)

I started with ubuntu 8.4
Then I installed the LAMP task, and addrd php, mysql, and phpmyadmin
I added apache password protection and tested phpmyadmin.

I then installed asterisk from source using 1.6.2 branch and subversion. The target machine is a XEN vm, so the only add-on I included was ILBC and ODBC support.

I installed asterisk to autostart and tested to see if I could connect to asterisk after rebooting (asterisk -vvvr)

At this point, asterisk seems to be running on top of LAMP.

I downloaded the 2.7 branch of freepbx (svn)
I created an asterisk user to run apache, initialized the asterisk and asteriskcdr databases.
I tweaked the memory limits for PHP up (100MB download), and tweaked ownership of various directories conferring them to asterisk.

Then I ran the install_amp script.

When I called up "admin:, it advised me to reload, and then I had NO modules.
I went to module maint. Queried online modules, and attempted to install JUST the core module.

After confirming, the install HANGS at the freepbx ORANGE BOX. No text. Just the Blank Orange Box.

This feels like I am -almost- home.

Any thoughts?

(Subscribing to email updates)

After a very long time the orange box “times out” and this message is displayed:

(domainname)…/admin/config.php?type=tool&display=modules&extdisplay=process&quietmode=1&module_repo=supported&moduleaction[announcement]=0&moduleaction[asterisk-cli]=0&moduleaction[asteriskinfo]=0&moduleaction[backup]=0&moduleaction[blacklist]=0&moduleaction[callback]=0&moduleaction[callforward]=0&moduleaction[callwaiting]=0&moduleaction[cidlookup]=0&moduleaction[conferences]=0&moduleaction[core]=downloadinstall&moduleaction[customappsreg]=0&moduleaction[customerdb]=0&moduleaction[dashboard]=0&moduleaction[daynight]=0&moduleaction[dictate]=0&moduleaction[disa]=0&moduleaction[donotdisturb]=0&moduleaction[dundicheck]=0&moduleaction[fax]=0&moduleaction[featurecodeadmin]=0&moduleaction[findmefollow]=0&moduleaction[framework]=0&moduleaction[fw_ari]=0&moduleaction[fw_fop]=0&moduleaction[gabcast]=0&moduleaction[iaxsettings]=0&moduleaction[infoservices]=0&moduleaction[inventorydb]=0&moduleaction[irc]=0&moduleaction[ivr]=0&moduleaction[javassh]=0&moduleaction[languages]=0&moduleaction[logfiles]=0&moduleaction[manager]=0&moduleaction[miscapps]=0&moduleaction[miscdests]=0&moduleaction[music]=0&moduleaction[outroutemsg]=0&moduleaction[paging]=0&moduleaction[parking]=0&moduleaction[pbdirectory]=0&moduleaction[phonebook]=0&moduleaction[phpagiconf]=0&moduleaction[phpinfo]=0&moduleaction[pinsets]=0&moduleaction[printextensions]=0&moduleaction[queueprio]=0&moduleaction[queues]=0&moduleaction[recordings]=0&moduleaction[restart]=0&moduleaction[ringgroups]=0&moduleaction[sipsettings]=0&moduleaction[sipstation]=0&moduleaction[speeddial]=0&moduleaction[timeconditions]=0&moduleaction[versionupgrade]=0&moduleaction[vmblast]=0&moduleaction[voicemail]=0&moduleaction[weakpasswords]=0&moduleaction[fw_langpacks]=0 might be temporarily down or it may have moved permanently to a new web address.

I have installed from the tar and from the svn 2.7 tag and things are a -little- different.

When I frist installed from the 2.7 branch, there were NO modules loaded by default, but all online modules could be seen but not downloaded.

When I downloaded from the svn tag or the 2.7 tar, I get a minimal set of modules (core, voicemail, and a few others, and once again i can check for updates online.

However, the same problem still persists:

Whenever I try to select and install a module, I press confirm, the orange block appears, and nothing happens until the whole process times out. In firefox there is never an error message. in Chrome, I can see the html page is not available message posted earlier.

I have all of my build instructions in shell files, and have reviewed what is known about directory permissions, etc.

the ONLY thing that is a bit odd. the .sh file in freepbx admin/modules that loads modules locally will not run until I manually approve the freepbx host and let the system add it to my known hosts file. I can then obtain local copies of the modules. The freepbx admin page sees these local modules, but will NOT install a module whether it is local or on the freepbx svn library.

This is a Script to Install LAMP on a bare bones Linux Server (ubuntu 8.04)

Script Created June 1, 2010 By rparker

run this script by typing: #sh lamp.sh

apt-get update # Get Current Versions of Package Softare
apt-get upgrade # Install Current Versions of Package Software
apt-get install apache2 # the apcahe2 web server
apt-get install php5 # php scripting language
apt-get install php5-mysql #adds mysql connections to php scripting language
apt-get install libapache2-mod-php5 # integrate PHP language into apache
apt-get install mysql-server # install "best Version of Mysql server
apt-get install libapache2-mod-auth-mysql # Enable http authentication against a mysql database (Needed for phpmyadmin)
apt-get install phpmyadmin # Install PHPmyadmin
htpasswd -c /etc/apache2/.htpasswd admin # Create a password file and add user admin to the file
#cp the contents htaccesstemplate into the config of the default sites available in the root directory section
cp test.php /var/www/test.php # try: http://dom/test.php
cp htaccesstemplate /var/www/.htaccess # try: http://dom/test.php

Change Apache to run as user asterisk

adduser asterisk --disabled-password --no-create-home --gecos "asterisk PBX user"
sed -i “s/www-data/asterisk/” /etc/apache2/envvars

edit apache for freepbx php capabilities

sed -i “s/AllowOverride None/AllowOverride All/” /etc/apache2/apache2.conf # Let local .htaccess files modify apache2 behavior
sed -i “s/post_max_size = 8M/post_max_size = 100M/” /etc/php5/apache2/php.ini
sed -i “s/upload_max_filesize = 2M/upload_max_filesize = 20M/” /etc/php5/apache2/php.ini
sed -i “s/memory_limit = 16M/memory_limit = 100M/” /etc/php5/apache2/php.ini

/etc/init.d/apache2 restart # Restart Apache

#Setup the system

apt-get install subversion # source code management
apt-get install m4 # the UNIX Macroprocessor
apt-get install ncurses-dev
apt-get install unixODBC-dev
apt-get install libtool
apt-get install openssl
apt-get install postfix # so we can send mail (choose internet site)
apt-get install sysvconfig # to support the service command
apt-get install doxygen # documentation package

Freepbx notes from textbook

apt-get install build-essential # c++, make, and c development libraries
apt-get install autoconf automake libtool flex bison linux-headers-$(uname -r) sox curl mysql-client lame # Assorted Tools
apt-get install libssl-dev libnewt-dev libncurses5-dev libmysqlclient-dev # Assorted Development libraries
apt-get install php5-gd php5-curl php5-mcrypt php5-xmlrpc php5-mhash php5-suhosin php5-common php5-xsl # More php5 modules for asterisk
apt-get install php5-cli # So that php can be executed at the command line…
apt-get install php-pear # pear is the php "code library manager"
pear install DB

apt-get install libxml2 # xml documentation package
apt-get install libxml2-dev

#Change to the proper directory

cd /usr/src/

Get asterisk

svn co http://svn.digium.com/svn/asterisk/tags/1.6.2.9/ asterisk

addons are now in a subfolder of asterisk

#or for 1.6.2 comment out the above line, and uncomment the line below.

dahdi is no longer needed for timing in 1.6.2

#svn co http://svn.digium.com/svn/asterisk/branches/1.6.2/ asterisk

Compile asterisk

cd /usr/src/asterisk/
./contrib/scripts/get_ilbc_source.sh
cp /usr/src/asterisk/contrib/scripts/codecs /usr/src/asterisk/codecs/
cd /usr/src/asterisk
make clean
./configure
make menuselect
make
make install

Don’t need samples if we use freepbx

make samples

make progdocs
make config # builds autostart

Change the asterisk run dir

sed -i “s/astrundir => /var/run/astrundir => /var/run/asterisk/” /etc/asterisk/asterisk.conf

recreate asterisk run dir at boot

echo “mkdir /var/run/asterisk” >> /etc/rc.local
echo “chown -R asterisk:asterisk /var/run/asterisk” >> /etc/rc.local

the asterisk user (apache and freepbx need to own these dirs

chown -R asterisk:asterisk /var/spool/asterisk/
chown -R asterisk:asterisk /var/log/asterisk/
chown -R asterisk:asterisk /var/lib/asterisk/moh

cd /usr/src/
svn co http://svn.freepbx.org/freepbx/tags/2.7.0/ freepbx
cd freepbx

create the databases

mysqladmin -u root -ppwd DROP asterisk
mysqladmin -u root -ppwd DROP asteriskcdrdb
mysqladmin -u root -ppwd create asterisk
mysqladmin -u root -ppwd create asteriskcdrdb
mysql -u root -ppwd asterisk < SQL/newinstall.sql
mysql -u root -ppwd asteriskcdrdb < SQL/cdr_mysql_table.sql
mysql -u root -ppwd <<-END_PRIVS
GRANT ALL PRIVILEGES ON asterisk.* TO asteriskuser@localhost IDENTIFIED BY “pwd”;
GRANT ALL PRIVILEGES ON asteriskcdrdb.* TO asteriskuser@localhost IDENTIFIED BY “pwd”;
flush privileges;
END_PRIVS

remove the config file below, if install needs to be rerun

rm -f /etc/amportal.conf

#Since the Asterisk default moh directory (/moh) and the Freepbx default moh directory (/mohmp3) are different we need to create a symbolic link so moh files are #where FreePBX expect them to be.
ln -s /var/lib/asterisk/moh /var/lib/asterisk/mohmp3

cd /usr/src/freepbx/
./install_amp install --my-svn-is-correct

echo “/usr/sbin/amportal start &” > /etc/rc.local # configure to autostart
chown asterisk:asterisk /etc/amportal.conf

amportal start

I did turn on the PHP “magicquotes” thing, but that manual edit did not make it into the script, yet.

The lamp, asterisk, and install scripts run to completion on a virtualbox 10.4 system, and modules are installed properly.

The same scripts run to completion on then rented cloud XEN 8.4 server, and module installs hand at the orange box.

Could there be some small “curl”-like tool missing from my 8.4 server? Something that is not needed up to and until we click “process” in module installation??

I have worked on this for 3+ days, and I am going to write this off (for the moment) as a problem with the cloud hosting service which provided the XEN/Ubuntu 8.4 platform. There may be something about their linux/network configuration that is a showstopper.

These scripts seem to run just fine on a 256MB slicehost.com VM with 10.4 ubuntu.

I am now moving into the deeper waters of setting up trunks, extensions, etc.

If someone ever reads this, and has an idea of a dependency, a log, a code snippet, or something else to inspect - I am keeping the defective VM around for awhile. So, drop me a note! Thanks in Advance.

(The other service is about 1/2 the price of slicehost.)