Some Linux installation notes - and problems!
Posted by: Luke ()
Date: July 07, 2008 05:16AM

Last week I thought I'd do some work and install OF on a Linux machine & write a small howto for anyone else that wanted to do the same. I see a few queries on local installation so figured it might be useful.

Unfortunately, some forty hours later, I am still unable to write the howto - I'd thought that I would use Mandriva since it's also a French distribution & it would be nice to have an all-french software combination....

... so instead of writing the howto I thought I'd just write up some notes as to what happened in my attempts so that others may benefit from the time I've spent. If someone has successfully installed V2 on Mandriva I'd be very happy to hear but I was only successful in installation v1.3 at this time.

Some *rough* notes below:

Grab install ISO’s for Mandriva from

Burn CD’s, put in CD1 to your machine, set it to start from a CD & run the install.

I install the options for network server, network client and don’t install the multimedia option.

urpmi.addmedia contrib with media_info/
urpmi.addmedia main with media_info/
urpmi.removemedia "Mandriva Linux - 2008.1 (Free) - i586 CD1"
urpmi.removemedia "Mandriva Linux - 2008.1 (Free) - i586 CD2"
urpmi.removemedia "Mandriva Linux - 2008.1 (Free) - i586 CD3"
urpmi wget bzip2 unzip zip openssl fileutils ncftp flex libxorg-x11-devel gcc gcc-c++
urpmi MySQL MySQL-client libmysql15-devel
chkconfig mysqld on
/etc/init.d/mysqld start
urpmi apache-mod_suexec apache-mod_ssl apache-mod_php libphp5_common5 php-bz2 php-calendar php-ctype php-curl php-devel php-dio php-dom php-eaccelerator php-enchant php-esmtp php-event php-exif php-fam php-ffmpeg php-fileinfo php-filepro php-ftp php-gd php-gettext php-gmp php-iconv php-id3 php-idn php-imap php-imlib2 php-mailparse php-mbstring php-mcache php-mcrypt php-mhash php-ming php-mysql php-mysqli php-ncurses php-newt php-odbc php-oggvorbis php-pcntl php-pcre php-pear-Net_IDNA php-posix php-pspell php-readline php-recode php-session php-shmop php-simplexml php-snmp php-soap php-sockets php-sqlite php-ssh2 php-suhosin php-sysvmsg php-sysvsem php-sysvshm php-tclink php-tcpwrap php-tidy php-xml php-xmlrpc php-zip php-ini curl libcurl4-devel perl-libwww-perl
chkconfig httpd on
/etc/init.d/httpd restart
urpmi libgeoip1 geoip libgeoipupdate0 awffull
cd /tmp
gunzip webalizer-2.01-10-static.gz
mv webalizer-2.01-10-static /usr/bin/webalizer
chmod 755 /usr/bin/webalizer
urpmi pear

*Note that I had a directory of pear install files so I copied them to /tmp/pear

pear install /tmp/pear/*
pear install --alldeps /tmp/pear/*
mv openflyers_v1_3_1 /var/www/html/
cd /var/www/html/
mv openflyers_v1_3_1/ of
chmod -R 775 of

*Let's get some useful stuff as well...

cd /tmp
rpm -Uvh webmin-1.420-1.noarch.rpm
rpm -Uvh nano-2.0.7-1.i386.rpm
nano /var/www/html/of/install/install.php

chmod –R 775 /var/www/html/of

nano /var/www/html/of/conf/config.php & set the PEAR path from:

define ('PEAR_DIRECTORY',''); to read:
define ('PEAR_DIRECTORY','/usr/share/pear');

also set:

define ('DEFAULT_LANG','@DEFAULT_LANG@'); to read
define ('DEFAULT_LANG','english');

nano /var/www/html/of/conf/connect.php & set define ('HOST','@HOST@'); to read:
define ('HOST','localhost');

define ('BASE','@BASE@');
define ('BASE','database_name');

Set the following with the appropriate username & password
define ('VISITOR','@USER@');

Using firefox navigate to http://localhost/of/install/install.php

Select your database name (eg ‘fly’) and let of create it for you.
Following on select your language & timezones as appropriate

After this I spent quite some hours attempting to get it to go, including altering php & apache settings/modules, all to no avail. Despite all this time I could not get it to operate successully at all.

In the end I decided I'd download XAMPP & give it a try - it works for me on a Windows box so....

/etc/init.d/httpd stop

/etc/init.d/mysqld stop

chkconfig httpd off
chkconfig mysqld off

rename pear bin files

download xampp & install per instructions from

set env to reflect /opt/lampp/bin

install OF1.3, switch to php4 & install (I found it would not install using PHP5, this is a useful function of XAMPP).

note, may need to set chmod –R 777 to OF dir, important to change later.

Then follow the instructions to install OF2, note it would not work using PHP4 under XAMPP so switch back to PHP5 & check.

At this point things went downhill the same way as they did with the native Mandriva install, although the error was a little different. I was able to get te OF2 welcome screen to come up but once the username/pass was entered it would die with a segmentation fault in Apache. I did many things, including disabling various modules etc in order to try and make it as similar as possible to the (working) Windows XAMPP install - information on the 'net suggested that this sort of error could be module related. Once again I could not get it to improve.

Finally I thought I'd try a different version of Mandriva - in fact Mandrake 10.1 - to see if it made a difference. Unfortunately 10.1 uses PHP4 as a default and there were various other things that needed upgrading so I decided to use the XAMPP method again. Same issue as below:

[Tue Jul 08 17:17:03 2008] [notice] child pid 3920 exit signal Segmentation fault (11)
[Tue Jul 08 17:18:24 2008] [notice] child pid 3921 exit signal Segmentation fault (11)

So that's it to date, sorry I'm unable to report success but as we speak I'm downloading a version of Ubuntu so I can try a debian-based distribution in case that works, I've really spent far too much time now & probably could be of more use translating some operational docs but I will report on my experiences with Ubuntu.

Rgds, Luke.

Options: ReplyQuote
Re: Some Linux installation notes - and problems!
Posted by: claratte ()
Date: July 07, 2008 09:44AM


It's seems very complicated!

To install OF2, you need tongue sticking out smileyHP 5, MySQL (maybe 4 or 5, I do not remember if it's work with 3)

You also need PEAR modules (list is in the wiki)

To install PEAR modules, you only need (with linux) to use pear command.

(you seem to have done all of this)

And do not forget to edit the php.ini file for some extensions required (XSL and some things like that)

That's all I guess...

(I got OF2 on Mandriva and our servers are on Debian)

Christophe LARATTE
OpenFlyers manager

Edited 1 time(s). Last edit at 07/07/2008 09:45AM by claratte.

Options: ReplyQuote
Re: Some Linux installation notes - and problems - UPDATE
Posted by: Luke ()
Date: July 07, 2008 10:57AM

Christophe, thanks for the reply - I agree that it should be straightforward, I was very surprised to find so much trouble. I have used Mandrake/Mandriva for nearly 10 years now so am reasonably familiar with it but it just didn't seem to work for me this time for some reason. I am interested to hear you're using it - what version I wonder?

Anyway tonight I tried with Ubuntu server 8.04 and it was a success! For those that are interested here is, essentially, what I did:

Download Ubuntu Server edition from

Make a bootable CD from the ISO file.

Insert into the PC & boot, install & setup according to your environment (IP address etc). Don't forget to install the LAMP options amongst other things.

Log into Ubuntu (by default it requires a separate login from root for security reasons so for many commands you'll need to issue the sudo predecessor). Personally I prefer to login directly as root so I changed my configuration to allow this.

sudo updatedb - I like to easily find files using the locate command & need to update the index database, I do this regularly.

I also like to use Webmin so I downloaded the .deb package from the webmin site to the /tmp directory & installed it:

sudo dpkg -i /tmp/webmin_1.420_all.deb

we need some other packages for webmin to work properly:

sudo apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl

So that gets us a running box, you don't need to do the webmin stuff but it can make it easier if you want to do other things with the server such as add users, manage Samba, Squid or whatever...

Now time to install PEAR since OF requires it:

sudo apt-get install php-pear

I have all the PEAR packages already so I create a pear directory under the /tmp directory and copy them all to there so I can install/upgrade as needed:

pear upgrade /tmp/pear/*
pear install pear/MDB2#mysqli

Now at this stage, because I already had a working copy of OF on my (Windows) laptop I simply copied the working OF directory over to the /var/www/html directory on the server. Don't forget to edit the conf files to reflect the different paths (if needed) & different pear directory (in this case /usr/share/php).

Set the file permissions for the next stage:

chmod -R 775 /var/www/of

Now it's time to copy the operational MySQL file, this must be done properly so I back it up with the following command that will allow easy re-creation on the Ubuntu server, don't forget you need to have the daemon running:

C:\xampp\mysql\bin>mysqldump -u root -p --databases of > c:\xxx\of.mysql
Enter password:

Copy the of.mysql file over to the /tmp directory on the server then:

mysql -u root -p < /tmp/of.mysql
Enter password:

That should (re)create the database file, now on the server.

Let's try navigating to http://server/of

Oops, looks like I forgot that I needed XSL:

apt-get install php5-xsl

Don't forget to reload Apache after the package install:

sudo /etc/init.d/apache2 force-reload

Ok, now it's time to navigate to localhost/of & try again. Hmmm, looks like some permission issues trying to access the of directory

chmod -R 777 /var/www/of (Yes I know you should never do this but I'm just trying to get it to work, I'll sort out the real problem later!). Try again - success, including the trial data I'd put in from the windows install.

Ok that's it, I've assumed some familiarity with Linux commands etc so these notes are not a complete howto and there is still some refining to do but you should get the idea. FWIW I use WinSCP & Putty on the Windows box to transfer files & issue remote commands. I'm still not happy with the Mandriva failure, the only other thing I can think of is that for some obscure reason the hardware could be causing a problem so I'm going to try the Ubuntu install on that box tomorrow (I used a different machine for this install). That said it's a proper Intel Server motherboard so I'd be surprised if it was a problem.

Hopefully this helps someone, I'll update further with any refinements/updates I make.

Edited 2 time(s). Last edit at 07/07/2008 11:06AM by Luke.

Options: ReplyQuote
Re: Some Linux installation notes - and problems!
Posted by: utopie ()
Date: July 07, 2008 04:13PM


Just for information, Christophe's notebook is a mandriva 2006 spring (i install it) and openflyers's servers are powered by debian etch 64 bit

openflyers team

Options: ReplyQuote
Re: Some Linux installation notes - and problems - UPDATE
Posted by: Luke ()
Date: July 07, 2008 08:17PM

Hi Stephane, thanks for the info, I was going to try it with 2006 but I could only find one of my install disks :-( Given time I'll try again with 2008.1 Spring on another machine (or a virtual machine) just in case it disagreed with this particular hardware for some reason.

I hope to try the Ubuntu install on the original [problem] machine today so perhaps that will tell me something! I will report back on how it goes.

Cordialement, Luke

Options: ReplyQuote
Re: Some Linux installation notes - and problems - UPDATE
Posted by: Luke ()
Date: July 08, 2008 12:22AM

Update, Ubuntu install as per my instructions above (remembering what I originally forgot first!) worked perfectly on the original machine :-)

Options: ReplyQuote
Re: Some Linux installation notes - and problems!
Posted by: claratte ()
Date: July 08, 2008 07:56PM

> what version I wonder?

Hopefully, Stéphane answered for me, I'm just a user not a server admin ;-)

May you put your config install process on our wiki? (here: )

If you haven't wiki write access, tell me, I will create an account.

Christophe LARATTE
OpenFlyers manager

Options: ReplyQuote
Re: Some Linux installation notes - and problems!
Posted by: Luke ()
Date: July 08, 2008 08:19PM

Hi Christophe, absolutely happy to put up the process on the wiki! Also I've been making some modifications to the PHP code etc, I'll email you directly regarding these things :-)


Options: ReplyQuote

Sorry, only registered users may post in this forum.
This forum powered by Phorum.