CentOS 5.0 기준
아파치 2.2.3
실행 : /etc/init.d OR service httpd start
설정파일 : /etc/httpd/conf
- 747라인 AddDefaultCharset UTF-8
- 391라인 디렉토리 인덱스 확인
AddType application/x-httpd-php .php .htm .php3 .html
AddType application/x-httpd-php-source .phps
UserDir public_html (362)
<Directory /home/*/public_html> (370-381)
홈폴더 : /var/www/html
기본 index.html
Mysql 5.0.45
실행 : /etc/init.d OR service mysqld start
DB파일위치 : /var/lib/mysql
소켓위치 : /var/lib/mysql/mysql.sock
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
기타관련 파일 위치 : /usr/bin
mysqladmin도 여기에 위치함
[root@firewall bin]# 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 firewall 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.comSupport MySQL by buying support/licenses at
http://shop.mysql.com [ OK ]
MySQL (을)를 시작 중: [ OK ]
=>처음 데몬을 실행하면 DB을 초기한다.
[root@firewall bin]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.0.45 Source distribution
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> quit
=>초기는 root 암호없이도 접속가능
[root@firewall ~]# mysqladmin -u root password '암호' => 암호설정
[root@firewall ~]# mysql -u root -p => 연결
Enter password:
PHP 5.1.6
설정파일 : /etc/php.ini
참고로 최신 CentOS 5.5 버전은
PHP 5.1.6
mysql 5.0.77
아파치 2.2.3
출처:본인글