Homepage

홈페이지 구축 관련 정리

Naan 2011. 6. 23. 16:01
반응형

리눅스 32bit / 64bit 아무거나 깐다
yum을 이용해서 아래 항목들을 업데이트를 한다

#yum install httpd
#yum install mysql
#yum install php
#yum install gd
#yum install php-gd

- yum 을 통해 php 설치하기 위해서 저장소에 아래 주소 입력 -
#vi /etc/yum.repos.d/CentOS-Base.repo

[c5-testing]
name=CentOS-5 Testing
baseurl=http://dev.centos.org/centos/$releasever/testing/$basearch/
enabled=1
gpgcheck=1
gpgkey=http://dev.centos.org/centos/RPM-GPG-KEY-CentOS-testing
includepkgs=php*

- mysql 암호 설정 -
#mysql -u root

mysql> use mysql;
mysql> update user set password=password('암호') where user='root';
Query OK, 2 rows affected (0.03 sec)
Rows matched: 2 Changed: 2 Warnings: 0
mysql> flush privileges;
mysql> quit

- mysql 백업 및 복구
백업
#mysqldump -uuser -ppassword dbname > backup.sql
복구
#mysql -uuser -ppassword dbname < backup.sql
복구전에 db를 만들어놔야 한다.

- phymyadmin 사용시 에러
사용시 mcrypt 에러가 날경우 아래와 같이 업데이트
#yum install libmcrypt
#yum install php-mcrypt

The configuration file now needs a secret passphrase (blowfish_secret) 에러발생시
phpmyadmin 폴더 이동
#mv config.sample.inc.php config.inc.php
#vi config.inc.php

(변경전)
$cfg['blowfish_secret'] = ''; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

(변경후)
$cfg['blowfish_secret'] = 'xxxxx'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */
xxxxx 부분 임의의 키 입력

제로보드나 그누보드사용으로 홈페이지 구축 가능하다.
그누보드 : http://sir.co.kr (가볍다)
제로보드 : http://www.xpressengine.com (약간무겁다)

반응형