라이브러리/시스템
CentOS에 Apache 2.2.19 소스설치
눌프
2011. 6. 3. 12:19
#1. 필요한 라이브러리설치
yum -y install ncurses-devel openssl-devel gd gd-devel bzip2 bzip2-devel
#2. OpenSSL 지원 설치
http://mirror.apache-kr.org//httpd/httpd-2.2.19.tar.gz
./configure --prefix=/usr/local/apache --enable-mods-shared=most --enable-modules=so --enable-ssl
make
make install
#3. 자동실행
#3-1. 실행파일복사
cp /usr/local/apache/bin/apachectl /etc/init.d/httpd
#3-2. 수정 (chkconfig 가 인식가능하도록)
vi /etc/init.d/httpd
#!bin/sh 밑에 아래 내용을넣는다.
# chkconfig: - 85 15
# description: Apache is a World Wide Web server.
# It is used to serve HTML files and CGI.
#3-3. chkconfig를 통해 서비스등록
chkconfig --add httpd
chkconfig --level 2345 httpd on
chkconfig --list httpd
#3-4. 확인
ntsysv 하면 파란 화면이뜬다.
여기서 httpd 에 * 가쳐져 있다면 자동실행된다.
#3-5. 서비스 시작
#service httpd start