1. 압축 해제
# tar xzvf apache_1.3.xx.tar.gz (http://www.apache.org/dist/) ==> /usr/local/apache 이동
# tar xzvf mysql-4.0.xx.tar.gz (http://www.mysql.com/) ==> /usr/local/mysql 이동
# tar xzvf php-4.3.x.tar.gz (http://www.php.net/) ==> /usr/local/php 이동

2. 사용자 등록
# groupadd mysql 
# useradd -g mysql mysql 

3. mysql directory:
#./configure --prefix=/usr/local/mysql --with-charset=euc_kr --localstatedir=/usr/local/mysql/data --disable-maintainer-mode --with-mysqld-user=mysql --enable-large-files -without-debug
# make 
# make install 

# ./scripts/mysql_install_db 
# chown -R root:mysql /usr/local/mysql 
# chown -R mysql:mysql /usr/local/mysql/data 

4. /etc/ld.so.conf파일에 다음 줄 추가:
/usr/local/mysql/lib/mysql 

5. mysql daemon 실행:
# cd /usr/local/mysql/bin 
# ./mysqld_safe --user=mysql & 

6. 암호 설정
# ./mysqladmin -u root password new_password

6-1. 부팅 시 mysql 자동실행 옵션
- support-files/mysql.server 파일을 /etc/rc.d/init.d로 복사
# chmod 755 mysql.server
# cp mysql.server /etc/rc.d/init.d/
- rc0.d와 rc3.d에 symbolic link 생성
# ln -s /etc/rc.d/init.d/mysql.server /etc/rc.d/rc0.d/K01mysql
# ln -s /etc/rc.d/init.d/mysql.server /etc/rc.d/rc3.d/S90mysql

7. apache directory:
# ./configure --prefix=/usr/local/apache

8. php directory:
# ./configure --with-mysql --with-xml --enable-track-vars --with-apache=../apache --with-zlib --with-gd --with-mod_charset --with-language=korean --with-charset=euc_kr
# make 
# make install
# cp php.ini-dist php.ini

9. apache directory:
# ./configure --prefix=/usr/local/apache --enable-module=rewrite --activate-module=src/modules/php4/libphp4.a --enable-module=so --enable-rule=SHARED_CORE
# make
# make install

10. /usr/local/apache/conf/httpd.conf 파일:
- ServerName 변경
ServerName localhost:80
- 'AddType image/x-icon .ico' 다음 줄에 아래 줄 추가
AddType application/x-httpd-php .php .phtml
AddType application/x-httpd-php-source .phps
- DirectoryIndex 부분 변경
DirectoryIndex index.html index.html.var index.php index.phtml 

10.1 부팅 시 apache 자동실행 옵션
- apachectl을 /etc/rc.d/init.d로 복사
# cp apachectl /etc/rc.d/init.d/httpd
- rc0.d와 rc3.d, rc5.d에 symbolic link 생성
# ln -s /etc/rc.d/init.d/apachectl /etc/rc.d/rc0.d/K90mysql
# ln -s /etc/rc.d/init.d/apachectl /etc/rc.d/rc3.d/S89mysql
# ln -s /etc/rc.d/init.d/apachectl /etc/rc.d/rc5.d/S89mysql

11. apache 재실행
# /usr/local/apache/bin/apachectl start

12. /usr/local/apache/htdocs에 test.php 생성:
<? phpinfo(); ?>

13. Zend Optimizer 설치
# tar zxvf ZendOptimizer-2.x.x-Linux_glibc21-i386.tar.gz
# cd ZendOptimizer-2.x.x-Linux_glibc21-i386
# ./install.sh

14. 테스트


'Tech: > Linux·PHP' 카테고리의 다른 글

Linux VMWare 설치 (RedHat 9.0)  (0) 2008.06.26
Apache + Tomcat 연동 설치  (0) 2008.06.26
Linux VMWare 설치  (0) 2008.06.26
PHP 암호화 모듈 설치  (0) 2008.06.26
Linux에 PHP + Apache + MySQL 설치하기  (0) 2008.06.26


Posted by 떼르미
,


자바스크립트를 허용해주세요!
Please Enable JavaScript![ Enable JavaScript ]