*DNS 먼저 설정을 한다
154번 DNS 를 설정한다.
vi
/var/named/kst11.zone
first.kst11.gor. IN
A 192.168.10.153
second.kst11.gor. IN
A 192.168.10.153
입력해준다.
systemctl
restart named.service
# DNS 재시작
nslookup
first.kst11.gor
# DNS 확인
*아파치 서버를 올린 153번을 수정해준다.
/app/apache/bin/apachectl stop
#아파치 서버 정지
httpd.conf에서 미리 주석처리를 해제해준다.
httpd-vhosts.conf 파일 설정
vi
/app/apache/conf/extra/httpd-vhosts.conf
documentroot 웹 홈 디렉토리
servername 도메인명
두개를 수정해줌.
NameVirtualHost
*:80
DocumentRoot /home/web/httpd/first
ServerName first.kst11.gor
ServerAlias www.dummy-host.example.com
ErrorLog "logs/dummy-host.example.com-error_log"
CustomLog logs/db01_log common
DocumentRoot /home/web/httpd/second
ServerName second.kst11.gor
ServerAlias www.dummy-host.example.com
ErrorLog "logs/dummy-host.example.com-error_log"
CustomLog logs/db01_log common
cd /home/web/httpd
cp
-R html first
cp
-R html second
아파치 서버 시작
/app/apache/bin/apachectl start
이상없이 되면 확인
댓글 없음:
댓글 쓰기