Apache+PHP+MySQL+Postgres
構築環境
CentOS (4.3)Apache (1.3.36)
PHP (4.4.2)
MySQL (4.1.20)
Postgres (8.1.4)
OpenSSL (0.9.8b)
$ tar -zxvf openssl-0.9.8b.tar.gz
$ cd openssl-0.9.8b/
$ ./config
--prefix=/usr/local
--openssldir=/usr/local/openssl
-fPIC
$ make
$ make test
$ su
# make install
**Apache(1.3.36) + mod_ssl(1.3.36)
$ tar -zxvf apache_1.3.36.tar.gz
$ tar -zxvf mod_ssl-2.8.27-1.3.36.tar.gz
$ cd mod_ssl-2.8.27-1.3.36/
$ ./configure
--with-apache=../apache_1.3.36
--with-ssl=../openssl-0.9.8b
--prefix=/usr/local/apache
--enable-shared=ssl
--enable-module=so
**Apache (1.3.36)
$ cd apache_1.3.36/
$ make
$ make certificate
$ su
# make install
**Postgres
$ su -
# useradd postgres
# mkdir /usr/local/pgsql
# chown postgres:postgres /usr/local/pgsql/
# su postgres
$ tar -zxvf postgresql-8.1.4.tar.gz
$ cd postgresql-8.1.4/
$ ./configure --enable-multibyte=EUC_JP
$ make all
$ make install
***PostgreSQL の実行まで
postgresユーザーの.bash_profileへ操作設定の記述をします。
PATH=$PATH:$HOME/bin:/usr/local/pgsql/bin
export POSTGRES_HOME=/usr/local/pgsql
export PGDATA=/home/postgres/data
export PGLIB=/usr/local/pgsql/lib
export LD_LIBRARY_PATH=/usr/local/pgsql/lib
その後にプロファイルをロードし、Postgres環境の初期化とPostmasterの起動を行います。
$ . .bash_profile ($ source .bash_profile)
$ initdb
$ pg_ctl start -l [LogFileName] -s -D /home/postgres/data/ -o -i
**MySQL
$ su -
# useradd mysql
# su mysql
$ tar xvzf ./mysql-standard-4.1.20-pc-linux-gnu-i686.tar.gz
$ cd mysql-standard-4.1.20-pc-linux-gnu-i686
$ ./configure
--prefix=/usr/local/mysql
--with-charset=ujis
--with-extra-charsets=all
--with-mysqld-user=mysql
--without-bench
--localstatedir=/home/mysql/data
$ make
$ su
# make install