apache のinstall

apache は専攻サーバ群の www サーバ で用いられている www サーバソフトである.


install

  1. 最新バージョン apache_1.3.20 を http://httpd.apache.org/ よりダウンロード.
    今回は自分のホームディレクトリにダウンロードした
  2. ホームディレクトリで圧縮ファイルを展開する.
    orange:~$ tar zxvf apache_1.3.20.tar.gz
    (一部抜粋)
    apache_1.3.20/ABOUT_APACHE
    apache_1.3.20/INSTALL
    apache_1.3.20/Makefile.tmpl
    apache_1.3.20/README

    それによって apache_1.3.20 というディレクトリができる.
    以下に展開されたファイルのうち大事そうなものを挙げるので 少し目を通しておくといいだろう.
    • README.configure: 圧縮ファイルの展開から make install までの説明.
    • Makefile.tmpl: Makefile を作るためのテンプレート
    • configure: 環境設定用のシェルスクリプト
    • src: Apache のソース本体の入ったディレクトリ
    • INSTALL: インストールの方法
    • conf: 設定ファイルの元の入ったディレクトリ

  3. apache_1.3.20 のディレクトリに移動して configure する.
    configure スクリプトはシステムの OS や環境を自動的に判別して,
    最適なコンパイル作業を行なえるようにするものである. (Makefileを作る)
    orange:~$ cd apache_1.3.20
    orange:~/apache_1.3.20$ ./configure
    (一部抜粋)
    Configuring for Apache, Version 1.3.20
    + Warning: Configuring Apache with default settings.
    + This is probably not what you really want.
    Creating Makefile

    (*)デフォルトでは /usr/local/apache/ 以下にインストールするようになる.
    インストールしたい場所を指定するには
    orange:~/apache_1.3.20 $ ./configure --prefix=[インストールするディレクトリ]
    ※ 今回は、インストールするディレクトリを /etc/apache にした.
    また, 事前にインストールされる場所を知るには
    orange:~/apache_1.3.20$ ./configure --show-layout
  4. make する.
    make コマンドによって実際にコンパイルされる.
    orange:~/apache_1.3.20 $ make
    ===> src
    make[1]: Entering directory `/home/hogehoge/apache_1.3.19'
    make[2]: Entering directory `/home/hogehoge/apache_1.3.19/src'
    ===> src/regex
    sh ./mkh -p regcomp.c >regcomp.ih
    gcc -I. -I../os/unix -I../include -DLINUX=2 -DUSE_HSREGEX -DUSE_EXPAT -I../lib/expat-lite -DNO_DL_NEEDED `../apaci` -DPOSIX_MISTAKE -c regcomp.c -o regcomp.o
    (後略)
  5. make install する.
    適切な場所へインストールされる.
    orange:~/apache_1.3.20 # make install
    make[1]: Entering directory `/home/hogehoge/apache_1.3.20'
    ===> [mktree: Creating Apache installation tree]
    ./src/helpers/mkdir.sh /etc/apache/bin
    ./src/helpers/mkdir.sh /etc/apache/bin
    ./src/helpers/mkdir.sh /etc/apache/libexec
    (中略)
    +------------------------------------------
    | You now have successfully built and installed the
    | Apache 1.3 HTTP server. To verify that Apache actually
    | works correctly you now should first check the
    | (initially created or preserved) configuration files
    |
    | /etc/apache/conf/httpd.conf
    |
    | and then you should be able to immediately fire up
    | Apache the first time by running:
    |
    | /usr/local/apache/bin/apachectl start
    |
    | Thanks for using Apache. The Apache Group
    | http://www.apache.org/
    +------------------------------------------
    以上でインストール終了.

設定


Last modified Jul.5 2001
honey@ep.sci.hokudai.ac.jp