네임 서버가 안되요.

littletirano의 이미지

ping 으로요 ping ns.abc.com 하면 ping 이 가거든요.
그런데, ping www.abc.com 하면 ping이 안가요.

#여기서 나오는 아이피나 네임은 임의로 바꿔서 올렸습니다.

아래가 설정 파일 이거든요.
고정 아이피로 네임 기반 버추얼 호스팅 하구요.

네임 서버는 ns.abc.com 이라고 하고
www.123.com & www.456.com 를 호스팅 해 줄거예요.

################################

-/etc/named.conf

controls {
inet 127.0.0.1 allow { localhost; } keys { rndckey; };
};
zone "." IN {
type hint;
file "named.ca";
};

zone "localhost" IN {
type master;
file "localhost.zone";
allow-update { none; };
};

zone "0.0.127.in-addr.arpa" IN {
type master;
file "named.local";
allow-update { none; };
};

zone "abc.com" IN {
type master;
file "abc.zone";
allow-update { none; };
};

zone "987.654.321.in-addr.arpa" IN {
type master;
file "abc.rev";
allow-update { none; };
};

zone "123.com" IN {
type master;
file "123.zone";
};

zone "456.com" IN {
type master;
file "456.zone";
};
include "/etc/rndc.key";

########################

-/var/named/abc.zone

$TTL 86400
@ IN SOA ns.abc.com. webmaster.abc.com. (
2003040603 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ;
IN NS ns.abc.com.
IN A 123.456.789.963
IN MX 10 abc.com.

localhost IN A 127.0.0.1
@ IN A 123.456.789.963
ns IN A 123.456.789.963
ns.abc.com. IN A 123.456.789.963
mail IN CNAME @
www IN CNAME @

################################

-/var/named/abc.rev

[root@bidcons named]# vi bidcons.rev

$TTL 86400
@ IN SOA ns.abc.com. webmaster.abc.com. (
2003040603 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ;
IN NS ns.abc.com.
IN MX 10 abc.com.
963 IN PTR ns.abc.com.

###################################

[root@abc named]# nslookup
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.
> ns.abc.com
Server: 123.456.789.963
Address: 123.456.789.963#53

Name: ns.abc.com
Address: 123.456.789.963
> www.abc.com
Server: 123.456.789.963
Address: 123.456.789.963#53

www.abc.com canonical name = abc.com.
Name: abc.com
Address: 123.456.789.963
> server ns.abc.com
Default server: ns.abc.com
Address: 123.456.789.963#53
> ns.abc.com
Server: ns.abc.com
Address: 123.456.789.963#53

Name: ns.abc.com
Address: 123.456.789.963
> set type=NS
> ns.abc.com
Server: ns.abc.com
Address: 123.456.789.963#53

*** Can't find ns.abc.com: No answer
>

###############################

[root@abc named]# vi /var/log/messages

Apr 7 11:16:01 abc named[1501]: dns_master_load: 123.zone:13: ignoring out-of-zone data (ns.abc.com)
Apr 7 11:16:01 abc named[1501]: dns_master_load: 123.zone:14: ignoring out-of-zone data (abc.com)

#################################

[root@abc root]# perl dnswalk -raFl www.abc.com.
Checking www.abc.com.
BAD: SOA record not found for www.abc.com.
BAD: www.abc.com. has NO authoritative nameservers!
BAD: All zone transfer attempts of www.abc.com. failed!
0 failures, 0 warnings, 3 errors.

그리고
[root@abc root]# perl dnswalk -raFl abc.com.
Checking abc.com.
BAD: abc.com. has only one authoritative nameserver
Getting zone transfer of abc.com. from ns.abc.com...done.
SOA=ns.abc.com contact=webmaster.abc.com
0 failures, 0 warnings, 1 errors.

이렇게 하면 에러가 줄구요.

위에 보듯이 이렇게 에러가 났는데. 어떻게 무엇을 고쳐야 할까요?

sunyzero의 이미지

@ IN A 123.456.789.963
ns IN A 123.456.789.963
ns.abc.com. IN A 123.456.789.963

이 세 라인은 의미가 이상하네요. 빼고하세요. 보면 너무 중복된것들이 많습니다. 자세하게 하우투같은 문서를 읽어보시고 하세요.

간단하게 이정도면 될것 같습니다.

$TTL 86400
@ IN SOA ns.abc.com. webmaster.abc.com. (
2003040603 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; 
        IN  NS  ns.abc.com.
        IN  A   123.456.789.963
;   
ns      IN  A   123.456.789.963
mail    IN  A   123.456.789.963
@       IN  MX  10  mail
www     IN  A   123.456.789.963

========================================
* The truth will set you free.

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.