Geomoose on RHEL: Difference between revisions
Brian Wilson (talk | contribs) mNo edit summary |
Brian Wilson (talk | contribs) |
||
Line 33: | Line 33: | ||
sudo yum install php php-devel php-gd php-pear-Net-Curl | sudo yum install php php-devel php-gd php-pear-Net-Curl | ||
sudo yum install zlib-devel | |||
'''SQLite''' I don't see a php sqlite package for RHEL | '''SQLite''' I don't see a php sqlite package for RHEL | ||
Line 60: | Line 61: | ||
sudo ldconfig | sudo ldconfig | ||
Libraries have been installed in: | It should say: | ||
/usr/ | Libraries have been installed in: | ||
/usr/lib64/php/modules | |||
To see if it's bound correctly, I check thusly | To see if it's bound correctly, I check thusly | ||
ldd /usr/ | ldd /usr/lib64/php/modules/php_mapscript.so | grep libpq | ||
libpq.so.5 => '''/usr/pgsql-9.1/lib/libpq.so.5''' (0x00007fe3fe65e000) | libpq.so.5 => '''/usr/pgsql-9.1/lib/libpq.so.5''' (0x00007fe3fe65e000) | ||
Latest revision as of 14:57, 7 May 2013
Versions
Really it's CentOS but who is asking? 6.2 I think. And Geomoose 2.6.1
== PostgreSQL
The default postgresql packages are far too old (8.4 vs 9.1 or 9.2) for Geomoose.
When installing a newer PostgreSQL on RHEL, use the postgres developer group RPM repository. If you already have a version of PostgreSQL running then you will need to deal with migrating the data and config.
sudo rpm -ivh http://yum.postgresql.org/9.1/redhat/rhel-6-x86_64/pgdg-centos91-9.1-4.noarch.rpm sudo yum install postgresql91-server postgresql91-contrib postgresql91-devel sudo ldconfig
If you don't have a version of postgresql install then
sudo service postgresql-9.1 initdb
(then edit the pg_hba.conf and postgresql.conf files in /var/lib/pgsql/9.1/data
sudo chkconfig postgresql-9.1 on sudo service postgresql-9.1 start
Prerequisite packages
# Always a good first step yum update
Recommended by the Geomoose page: php5 php5-dev php5-gd php5-pgsql php5-sqlite php-pear php5-curl
sudo yum install php php-devel php-gd php-pear-Net-Curl sudo yum install zlib-devel
SQLite I don't see a php sqlite package for RHEL
mapserver
wget http://download.osgeo.org/mapserver/mapserver-6.2.1.tar.gz tar xzvf mapserver-6.2.1.tar.gz cd mapserver-6.2.1 ./configure \ --with-php \ --with-agg \ --with-gd \ --with-wfs \ --with-wmsclient \ --with-wfsclient \ --with-postgis \ --with-proj \ --with-geos \ --with-freetype \ --with-gdal \ --with-ogr \ --with-python \ --with-zlib make sudo make install sudo ldconfig
It should say:
Libraries have been installed in: /usr/lib64/php/modules
To see if it's bound correctly, I check thusly
ldd /usr/lib64/php/modules/php_mapscript.so | grep libpq
libpq.so.5 => /usr/pgsql-9.1/lib/libpq.so.5 (0x00007fe3fe65e000)
I get the extension to load by doing this:
cd /etc/php.d/ sudo sh -c 'echo "# Enable mapserver mapscript extension" > mapscript.ini' sudo sh -c 'echo extension=/usr/local/lib/php/extensions/no-debug-non-zts-20100525/php_mapscript.so >> mapscript.ini' sudo apachectl restart