# su -

# useradd username

# passwd username

(삭제시 userdel -rf username)

# su 사용자계정

# cd;mkdir public_html;chmod 701 public_html;cd ..

# chomod 701 계정명

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

디비 생성

# mysql -u root -p

mysql >    create database dbname;

mysql >  grant all privileges on dbname.* to 'username'@'localhost' identified by 'password' with grant option;


flush privileges;

(권한부여)


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

가상호스트

#  vi /etc/httpd/conf/httpd.conf

(Cent OS의 경우)

<VirtualHost *:80>
ServerAdmin moon@moon.com(담장자이메일)
DocumentRoot "/home/moon/www"(계정디렉터리)
ServerName moon.com(도메인주소)
ServerAlias www.moon.com (추가도메인주소)
< /VirtualHost>

추가

아파치 재시작


+ Recent posts