dns 설정을 하였는데 ip주소를 못 찾네요 도와주세요

ddtrf123의 이미지

DNS 공부할려고 DNS 설정을 하였는데
nslookup을 하면

[root@ns ~]# nslookup www.xxx.com
Server: 192.168.5.5
Address: 192.168.5.5#53

** server can't find www.xxx.com: SERVFAIL

이렇게 뜹니다
어디가 뜰렸길레 재디로 안나오는걸까요?
아래는 설정 파일들 입니다
-------------------------
named.conf
-------------------------
options
{
// Put files that named is allowed to write in the data/ directory:
directory "/var/named"; // "Working" directory
dump-file "data/cache_dump.db";
statistics-file "data/named_stats.txt";
memstatistics-file "data/named_mem_stats.txt";
listen-on port 53 { 192.168.5.5; 127.0.0.1; };
//query-source address=port 53;
allow-query { any; };
allow-query-cache { any; };

recursion yes;
};

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

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

zone "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa" IN {
type master;
file "named.loopback";
allow-update { none; };
};

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

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

zone "xxx.com" IN {
type master;
file "xxx.com.zone";
allow-update { none; };
};
-----------------------------------
zone파일입니다.
-----------------------------------

$ORIGIN xxx.com.
$TTL 86400
@ IN SOA ns root (
2013122712 ; serial
1D ; refresh
1H ; retry
1W ; expire
3H ) ; minimum
IN NS ns.

ns. IN A 192.168.5.5
time. IN A 192.168.5.3
www. IN A 192.168.5.5
~
~
~

익명 사용자의 이미지

. 빼야 될 것 같습니다.

익명 사용자의 이미지

결과는 같습니다.

dgkim의 이미지

뺄점은 빼고, 붙일 점은 붙인 결과가 아래와 같습니다.

$ORIGIN xxx.com.
$TTL 86400
@       IN  SOA ns.xxx.com. root.xxx.com. (
        2013122712 ; serial
        1D ; refresh
        1H ; retry
        1W ; expire
        3H ) ; minimum
 
        IN NS ns.xxx.com.
 
ns      IN A 192.168.5.5
time    IN A 192.168.5.3
www     IN A 192.168.5.5

즉, SOA에서는 보통 .이 붙은 fqdn을 사용하고,
A, NS의 이름은 .없는 이름. 값은 .있는 이름.

--
http://www.dgkim.net/

ddtrf123의 이미지

결과는 여전히 같습니다.

dgkim의 이미지

내용에 문제가 있나 테스트를 했는데, 내용은 문제가 아니고,

named.conf 파일에서 file 항목을 전체 경로를 넣어서 테스트 해보십시오.
ex. file "/etc/bind/db.dgkimdgkim.net";

하신 것과 같이 전체경로가 없이 파일명만 넣으니 동작하지 않습니다.
(ubuntu bind)

파일명만 넣으면 아래와 같은 로그가 syslog에서 발견됩니다.

Dec 28 15:49:52 ns named[1211]: zone dgkimdgkim.net/IN: loading from master file db.dgkimdgkim.net failed: file not found
Dec 28 15:49:52 ns named[1211]: zone dgkimdgkim.net/IN: not loaded due to errors.
Dec 28 15:49:52 ns named[1211]: reloading zones succeeded
root@ns:/var/log# nslookup
> server localhost
Default server: localhost
Address: 127.0.0.1#53
> set type=ns
> dgkimdgkim.net
Server:		localhost
Address:	127.0.0.1#53
 
** server can't find dgkimdgkim.net: SERVFAIL

--
http://www.dgkim.net/

ddtrf123의 이미지

문제는 zone 파일의 소유권이였습니다.
소유권이 root로 되어있으니 zone을 못찾았던것 같습니다.

댓글 달기

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
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.