OpenBSD phpMyAdmin PDF Print E-mail
User Rating: / 1
PoorBest 
Written by Bart Dorlandt   
Sunday, 10 June 2007 16:42

(At the time of writing I use OpenBSD 4.0)

phpMyAdmin can be used to administer mysql from a webfrontend. This is very useful if you do not master the art of MySQL. To install phpMyAdmin use the following commands. This install is an example of what needs to be done if PHP5 and MySQL aren't yet installed. If they are the installation process might be a bit different. (I use the hardened version of PHP5, so you'll have to choose all the hardened versions eg. gd, mbstring)

But before we can install these packages, we will have to make sure some files are in place. These files are needed for the package: php5-gd-5.1.4-hardened. Execute the following commands. These will download the tgz-package xbase40.tgz, extract 2 files from it and places them in the correct location. NOTE: make sure you are root.

# if you don't have wget use this command:
pkg_add -i ftp://ftp.openbsd.org/pub/OpenBSD/4.0/packages/i386/wget-1.10.2p0.tgz

cd /tmp
wget ftp://ftp.calyx.nl/pub/OpenBSD/4.0/i386/xbase40.tgz
cd /
tar xzpf /tmp/xbase40.tgz ./usr/X11R6/lib/libXpm.so.7.0
tar xzpf /tmp/xbase40.tgz ./usr/X11R6/lib/libfreetype.so.13.1
tar xzpf /tmp/xbase40.tgz ./usr/X11R6/lib/libX11.so.9.0

pkg_add -i php5-gd-5.1.4-hardened

pkg_add -i phpMyAdmin
# it will ask for some other packages, choose the following
# -- php5-gd-5.1.4-hardened
# -- php5-mbstring-5.1.4-hardened
# -- php5-mcrypt-5.1.4-hardened
# -- php5-mysql-5.1.4-hardened
# -- mysql-client-5.0.24a

/usr/local/sbin/phpxs -s
/usr/local/sbin/phpxs -a mbstring
/usr/local/sbin/phpxs -a mcrypt
/usr/local/sbin/phpxs -a mysql
cp /usr/local/share/examples/php5/php.ini-recommended /var/www/conf/php.ini
mkdir /var/www/tmp
chmod ugo+rwxt /var/www/tmp
cat /var/www/conf/httpd.conf | sed 's/#AddType application\/x-httpd-php .php/AddType application\/x-httpd-php.php/'> /var/www/conf/httpd.conf

# for configuring your php.ini a bit.
cat /usr/local/share/examples/php5/php.ini-recommended | sed 's/;session.save_path = "\/tmp"/session.save_path = "\/tmp"/' > php.ini

Last Updated on Friday, 13 February 2009 15:35
 


Related items: