- Version: 2.0.46
- Summary: HTTP server
Notes
Important and permanent services
should be built and installed locally to
the system where its data resides.
This avoids retransmission of the same data over the net
(e.g. a webserver hosting NFS traffice).
Prerequisites
This list is typical, but not set in stone.
The nature of the data being served to the web will guide
you in what's needed and what can be omitted.
Obtaining
Pull down Apache from
http://httpd.apache.org/
Unpack it under
/cis/src/net as usual.
cd /usr/local/src/net
<... download httpd-2.0.46.tar.gz ...>
gzip -dc httpd-2.0.46.tar.gz |tar xf -
cd httpd-2.0.46
Pull down mod_perl from
http://perl.apache.org/
Pull down PHP from
http://www.php.net/
Grab the bcmath extension for PHP at
http://www.php.net/extra/number4.tar.gz
as well.
Solaris Installation
For most systems, the stock
GNU layout is just fine.
Review the
config.layout file and ensure that it fits your needs.
If you need something different, create a
new layout and change
GNU
in the configuration below; don't edit the existing GNU layout entry.
Configure the Apache source tree.
CC='cc -xtarget=ultra' CFLAGS=-O \
CXX='CC -xtarget=ultra' CXXFLAGS=-O \
F77='f77 -xtarget=ultra' F77FLAGS=-O \
CPPFLAGS=-I/cis/include LDFLAGS='-L/cis/lib -R/cis/lib' \
./configure --enable-layout=GNU \
--with-mpm=prefork --with-ndbm --with-gdbm \
--enable-suexec \
--with-suexec-safepath=/bin:/usr/bin:/cis/bin:/usr/local/bin \
--enable-mods-shared=all
Review the configuration log; if everything looks good, go ahead and build.
If the build succeeds, install it.
gmake
gmake install
Set up an init script to start and stop it at runtime.
Though Apache does come with examples, I prefer this one instead.
Install this as
/etc/init.d/httpd with mode 755.
#!/bin/sh
/bin/env -i HOME=/ \
PATH=/bin:/cis/bin:/usr/local/bin \
SHELL=/bin/sh \
/usr/local/sbin/apachectl "$@"
exit "$?"
Then, install the appropriate symlinks.
ln -s ../init.d/httpd rc0.d/K16httpd
ln -s ../init.d/httpd rc1.d/K16httpd
ln -s ../init.d/httpd rc2.d/K16httpd
ln -s ../init.d/httpd rcS.d/K16httpd
ln -s ../init.d/httpd rc3.d/S50httpd
Now, you should probably go off and configure it by editing
/usr/local/etc/apache2.
Or, maybe you should
BuildingModPerl or
BuildPHP? now.
Tru64 Installation