본문 바로가기

Linux Server 구축/1-2. Web Server

APM - RPM 설치


APM (Apache WebServer & PHP & Mysql)을 패키지 관리자를 이용해서 설치한다.


1. APM 설치
& 확인

1-1. APM 설치

[root@localhost www2]# system-config-packages - 패키지 관리자를 이용해서 설치를 한다.

패키지 관리자 -> 서버 -> MySQL 데이터베이스
mod_auth_mysql-1:3.0.0-3.1.i386
mysql-connector-odbc-3.51.12-2.2.i386
mysql-dvel-5.0.45-7.el5.i386
mysql-server-5.0.45-7.el5.i386
php-mysql-5.1.6-20.el5.i386

패키지 관리자 -> 서버 -> 웹 서버
mod_auth_mysql-1:3.0.0-3.1.i386 - MySQL 데이터베이스에서 선택한 것과 같다.
php-5.1.6-20.el5.i386
php-mysql-5.16-20.el5.i386

위 사항 모두 체크하면 패키지 관리자(= yum 기능)로 업데이트하여 패키지를 설치한다.
의존성에 걸리는 것들은 알아서 알려주며 같이 설치해주면 된다.



-------------------------------------------------------------------

1-2. APM 설치 확인

[root@localhost ~]# rpm -qa | grep http - Apache 웹서버와 관련된 패키지 검색
httpd-manual-2.2.3-11.el5_1.centos.3
httpd-2.2.3-11.el5_1.centos.3
system-config-httpd-1.3.3.3-1.el5

[root@localhost ~]# rpm -qa | grep php - PHP와 관련된 패키지 검색
php-5.1.6-20.el5_2.1
php-pdo-5.1.6-20.el5_2.1
php-ldap-5.1.6-20.el5_2.1
php-cli-5.1.6-20.el5_2.1
php-mysql-5.1.6-20.el5_2.1
php-common-5.1.6-20.el5_2.1

[root@localhost ~]# rpm -qa | grep mysql - mysql과 관련된 패키지 검색
mod_auth_mysql-3.0.0-3.1
libdbi-dbd-mysql-0.8.1a-1.2.2
mysql-5.0.45-7.el5
mysql-connector-odbc-3.51.12-2.2
php-mysql-5.1.6-20.el5_2.1
mysql-devel-5.0.45-7.el5
mysql-server-5.0.45-7.el5

-------------------------------------------------------------------

1-3. 서비스 재시작

[root@localhost ~]# service httpd restart
httpd 를 정지 중:                                          [  OK  ]
httpd (을)를 시작 중:                                      [  OK  ]

[root@localhost ~]# service mysqld start
MySQL 데이타베이스를 초기화하는 중:  Installing MySQL system tables...
OK
Filling help tables...
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h server3 password 'new-password'
See the manual for more instructions.
You can start the MySQL daemon with:
cd /usr ; /usr/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd mysql-test ; perl mysql-test-run.pl

Please report any problems with the /usr/bin/mysqlbug script!

The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
                                                           [  OK  ]
MySQL (을)를 시작 중:                                      [  OK  ]

-------------------------------------------------------------------

1-4. php 정보 확인

[root@localhost ~]# cd /var/www/html
[root@localhost html]# ls
index.html
[root@localhost html]# vi phpinfo.php
[root@localhost html]# cat phpinfo.php
<?
phpinfo ();
?>


웹브라우저창에서  http://www.bban2.co.kr/phpinfo.php 라고 입력한다.
다음과 같은 화면이 나오면 PHP는 정상 설치된 것이다.



그리고 스크롤바를 내려서 Apache 관련 설명과 mysql에 관련된 설명이 있으면 모든 패키지가 제대로 설치가 된 것이다.



-------------------------------------------------------------------

2. 설치형 게시판을 설치해보자.

여기서 설치할 게시판들은 모두 PHP와 MySQK울 연동하여 작성되는 게시판이다.


2-1. 제로보드 설치 (http://bban2.tistory.com/141)

-------------------------------------------------------------------

2-2. 제로보드 XE 설치 (http://bban2.tistory.com/218)

-------------------------------------------------------------------

2-3. 그누보드 설치 (http://bban2.tistory.com/143)

-------------------------------------------------------------------

2-4. 테터툴즈 설치 (http://bban2.tistory.com/144)