0) 事前準備 # cd /usr/local # mkdir apr-httpd # mkdir apr-util-httpd # mkdir httpd-2.3 # cd /usr/local/src 1) httpd-2.3のダウンロード&解凍 # wget http://ftp.riken.jp/net/apache//httpd/httpd-2.3.12-beta.tar.bz2 --2011-06-09 16:02:25-- http://ftp.riken.jp/net/apache//httpd/httpd-2.3.12-beta.tar.bz2 ftp.riken.jp をDNSに問いあわせています... 134.160.38.1 ftp.riken.jp|134.160.38.1|:80 に接続しています... 接続しました。 HTTP による接続要求を送信しました、応答を待っています... 200 OK 長さ: 3987519 (3.8M) [application/x-bzip2] `httpd-2.3.12-beta.tar.bz2' に保存中 100%[============================================================================================================>] 3,987,519 1.65M/s 時間 2.3s 2011-06-09 16:02:27 (1.65 MB/s) - `httpd-2.3.12-beta.tar.bz2' へ保存完了 [3987519/3987519] # bzip2 -dc httpd-2.3.12-beta.tar.bz2 | tar xvf - httpd-2.3.12-beta/ httpd-2.3.12-beta/.deps httpd-2.3.12-beta/.gdbinit httpd-2.3.12-beta/ABOUT_APACHE httpd-2.3.12-beta/acinclude.m4 httpd-2.3.12-beta/ap.d httpd-2.3.12-beta/Apache.dsw httpd-2.3.12-beta/apache_probes.d httpd-2.3.12-beta/build/ httpd-2.3.12-beta/BuildAll.dsp httpd-2.3.12-beta/BuildBin.dsp httpd-2.3.12-beta/buildconf ・ ・ ・ 2) インストール(失敗) # cd httpd-2.3.12-beta # ls ABOUT_APACHE CHANGES LICENSE NWGNUmakefile VERSIONING build configure.in httpd.spec os test Apache.dsw INSTALL Makefile.in README acinclude.m4 buildconf docs include server BuildAll.dsp InstallBin.dsp Makefile.win README.platforms ap.d config.layout emacs-style libhttpd.dsp srclib BuildBin.dsp LAYOUT NOTICE ROADMAP apache_probes.d configure httpd.dsp modules support # ./configure --prefix=/usr/local/httpd-2.3 checking for chosen layout... Apache checking for working mkdir -p... yes checking build system type... i686-pc-linux-gnu checking host system type... i686-pc-linux-gnu checking target system type... i686-pc-linux-gnu Configuring Apache Portable Runtime library ... checking for APR... no configure: error: APR not found. Please read the documentation. APRのパッケージがねーとさ (httpd-2.3だとaprのパッケージはv1.3以上が必要) ------------------------------------------------------------------------------------------- 3) aprパッケージインストール # cd /usr/local/src # wget http://ftp.riken.jp/net/apache//apr/apr-1.4.5.tar.gz --2011-06-09 16:20:48-- http://ftp.riken.jp/net/apache//apr/apr-1.4.5.tar.gz ftp.riken.jp をDNSに問いあわせています... 134.160.38.1 ftp.riken.jp|134.160.38.1|:80 に接続しています... 接続しました。 HTTP による接続要求を送信しました、応答を待っています... 200 OK 長さ: 994320 (971K) [application/x-gzip] `apr-1.4.5.tar.gz' に保存中 100%[============================================================================================================>] 994,320 3.59M/s 時間 0.3s 2011-06-09 16:20:49 (3.59 MB/s) - `apr-1.4.5.tar.gz' へ保存完了 [994320/994320] # tar zxvf apr-1.4.5.tar.gz # cd apr-1.4.5 --prefix=/usr/local/apr-httpd # ./configure # make # make install ------------------------------------------------------------------------------------------- 4) apr-utilパッケージインストール # cd /usr/local/src # wget http://ftp.riken.jp/net/apache//apr/apr-util-1.3.12.tar.gz --2011-06-09 16:21:05-- http://ftp.riken.jp/net/apache//apr/apr-util-1.3.12.tar.gz ftp.riken.jp をDNSに問いあわせています... 134.160.38.1 ftp.riken.jp|134.160.38.1|:80 に接続しています... 接続しました。 HTTP による接続要求を送信しました、応答を待っています... 200 OK 長さ: 769076 (751K) [application/x-gzip] `apr-util-1.3.12.tar.gz' に保存中 100%[============================================================================================================>] 769,076 2.75M/s 時間 0.3s 2011-06-09 16:21:05 (2.75 MB/s) - `apr-util-1.3.12.tar.gz' へ保存完了 [769076/769076] # tar zxvf apr-util-1.3.12.tar.gz # cd apr-util-1.3.12 # ./configure --prefix=/usr/local/apr-util-httpd --with-apr=/usr/local/apr-httpd # make # make install ------------------------------------------------------------------------------------------- 5) 再びインストール # cd httpd-2.3.12-beta # ./configure --prefix=/usr/local/httpd-2.3/ --with-apr=/usr/local/apr-httpd/ --with-apr-util=/usr/local/apr-util-httpd/ # make # make install # ------------------------------------------------------------------------------------------- 6) 起動&停止 # apachectl -k start httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName 何か出てるけど気にしない # ps -ef | grep httpd root 21522 1 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21523 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21524 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21525 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21526 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21527 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21528 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21529 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start apache 21530 21522 0 17:42 ? 00:00:00 /usr/sbin/httpd -k start root 21996 26838 0 17:45 pts/1 00:00:00 grep httpd とりあえず、動いているっぽい ブラウザでのアクセスも確認 # apachectl -k stop httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName # ps -ef | grep httpd root 22022 26838 0 17:46 pts/1 00:00:00 grep httpd 消えたから・・・おkかな?