가상호스트가 적용이안되네요. 모두 똑같은 곳으로 가버리네요
작성자 정보
- 김진명 작성
- 작성일
컨텐츠 정보
- 2,684 조회
- 0 추천
- 목록
본문
네임서버 설정을 마치고 nslookup abc.com 으로 하면 정상적으로 나타납니다.
[root@zest root]# nslookup abc.com
Note: nslookup is deprecated and may be removed from future releases.
Consider using the `dig' or `host' programs instead. Run nslookup with
the `-sil[ent]' option to prevent this message from appearing.
Server: 164.124.101.2
Address: 164.124.101.2#53
Non-authoritative answer:
Name: abc.com
Address: 12.34.56.78
으로 나타납니다.
그래서 다른 도메인을 하나 더 세팅했고 그도메인도 역시 정상적으로 나타납니다.
아파치에서 두 도메인 모두 가상호스트도 설정했고 apachectl configtest 를 하니 Syntax OK 로 나타납니다.
근데 문제는 두 도메인 모두 정상적으로 세팅했는데도 불구하고 각자의 홈디렉토리가 아닌
아파치 기본 홈디렉토리인 /usr/local/apache/htdoc 로 이동해버리더군요
가상 호스트 설정에는 아무 문제가 없는것 같구요.. 아래와 같습니다.
<VirtualHost 12.34.56.78>
ServerAdmin webmaster@abc.com
DocumentRoot /home/abc/public_html
ServerName abc.com
ServerAlias www.abc.com
</VirtualHost>
<VirtualHost 12.34.56.78>
ServerAdmin webmaster@def.com
DocumentRoot /home/def/public_html
ServerName def.com
ServerAlias www.def.com
</VirtualHost>
으로 설정했습니다.
근데 왜 저렇게 이동할까요?
그래서 httpd 를 실행해보니 다음과 같이 나오더군요.
도대체 머가문제일까요?
[root@zest root]# httpd --D
httpd: Could not determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
왜 이런게 뜰까요? 원래는 http -D 라던데 이건 안되고 httpd --D 로는 되네요
관련자료
-
이전
-
다음