• Willkommen im Linux Club - dem deutschsprachigen Supportforum für GNU/Linux. Registriere dich kostenlos, um alle Inhalte zu sehen und Fragen zu stellen.

DNS beantwortet querys nur für andere Hosts

ruthard

Newbie
DNS beantwortet querys nur für andere Hosts, jedoch nicht für sich selbst.


Ich habe Bind 9 installiert und einige Zonen definiert. Zb. Cobra.local, ruthard.local, christel.local.
In den Zonenfiles sind der zuständige DNS sowie je ein Web- und ftpserver definiert. Also www.cobra.local ,ftp.cobra.local etc..
(Wobei es sich in diesem Falle immer um den gleichen Rechner handelt.)

Von einem anderem Rechner kann ich nun mit Ping,ftp oder http auf diese Hosts zugreifen. Funktioniert perfekt. Z.b http://www.cobra.local ; http://www.ruthard local (Im Appache sind die entsprechenden Vhosts definiert, damit dann auch für jede Domäne die entsprechende Website angezeigt werden kann.)Ping und ftp geht ebefalls.

Der Rechner auf dem der DNS Dienst läuft, gibt auf diese Hosts keine Antwort, kann jedoch auf das Internet zugreifen.
In der IP-configuration ist nur der eigene Rechner als DNS configuriert.
Mit dnslookup wird erst mal die IP adresse des DNS angzeigt. Und diese stimmt auch.
Bei einem qry auf einen der genannten Hosts kommt auch die entsprechende IP zurück.
Jedoch Ping, ftp. http geht nicht

Eine Lösung wäre diese Hosts im /etc/hosts einzutragen, würd mir jedoch nicht so gefallen.

Wo könnte das Problem liegen?

Diagnostic
#----------------------------------------------------------------------------------
< Rcnamed status
Checking for nameserver BIND 9
number of zones: 9
debug level: 0
xfers running: 0
xfers deferred: 0
soa queries in progress: 0
query logging is OFF
server is up and running
[1A..running
#----------------------------------------------------------------------------------
dnslookup
>
Server: 192.168.1.1
Address: 192.168.1.1#53
>www.cobral.local:wq

Name: www.cobra.local
Address: 192.168.1.1
Server: 192.168.1.1
Address: 192.168.1.1#53
>exit
#/var/Log/messages
Nov 19 22:44:06 Viper named[5908]: starting BIND 9.2.3 -t /var/lib/named -u named
Nov 19 22:44:06 Viper named[5908]: using 1 CPU
Nov 19 22:44:06 Viper named[5908]: loading configuration from '/etc/named.conf'
Nov 19 22:44:06 Viper named[5908]: listening on IPv6 interfaces, port 53
Nov 19 22:44:06 Viper named[5908]: listening on IPv4 interface lo, 127.0.0.1#53
Nov 19 22:44:06 Viper named[5908]: binding TCP socket: address in use
Nov 19 22:44:06 Viper named[5908]: listening on IPv4 interface eth0, 192.168.1.1#53
Nov 19 22:44:06 Viper named[5908]: binding TCP socket: address in use
Nov 19 22:44:06 Viper named[5908]: command channel listening on 127.0.0.1#953
Nov 19 22:44:06 Viper named[5908]: command channel listening on ::1#953
Nov 19 22:44:06 Viper named[5908]: dns_master_load: 127.0.0.zone:9: 0.0.127.in-addr-arpa.0.0.127.in-addr.arpa: not at top of zone
Nov 19 22:44:06 Viper named[5908]: zone 0.0.127.in-addr.arpa/IN: loading master file 127.0.0.zone: not at top of zone
Nov 19 22:44:06 Viper named[5908]: zone 1.168.192.in-addr.arpa/IN: loaded serial 2004111400
Nov 19 22:44:06 Viper named[5908]: zone christel.local/IN: loaded serial 2004111400
Nov 19 22:44:06 Viper named[5908]: zone cobra.local/IN: loaded serial 2004111400
Nov 19 22:44:06 Viper named[5908]: zone form-atelier.local/IN: loaded serial 2004111400
Nov 19 22:44:06 Viper named[5908]: zone ruthard.local/IN: loaded serial 2004111400
Nov 19 22:44:06 Viper named[5908]: zone localhost/IN: loaded serial 42
Nov 19 22:44:06 Viper named[5908]: running


Config files

#/etc/named,conf
#
# /etc/named.conf
#
options {
directory "/var/lib/named";
dump-file "/var/log/named_dump.db";
statistics-file "/var/log/named.stats";
listen-on port 53 { any; };
listen-on-v6 { any; };
notify no;
forwarders { 194.183.128.35; 194.183.128.36; };
cleaning-interval 120;
# statistics-interval 60;
sortlist {
{ localhost; localnets; };
{ localnets; };
};
};
zone "localhost" in {
file "localhost.zone";
type master;
};

zone "form-atelier.local" in {
file "master/formatelier.local";
type master;
};

zone "ruthard.local" in {
file "master/ruthard.local";
type master;
};
"christel.local" in {
file "master/christel.local";
type master;
};

zone "cobra.local" in {
file "master/cobra.local";
type master;
};
zone "1.168.192.in-addr.arpa" in {
file "master/1.168.192.zone";
type master;
};
zone "0.0.127.in-addr.arpa" in {
type master;
file "127.0.0.zone";
allow-update { none; };
};
zone "." in {
type hint;
file "root.hint";
.------------------------------------

var/lib/localhost.zone
$TTL 1W
@ IN SOA @ root (
42 ; serial (d. adams)
2D ; refresh
4H ; retry
6W ; expiry
1W ) ; minimum

IN NS @
IN A 127.0.0.1

#-------------------------------------------------------------------------------
#\var\lib\127.0.0.zone
$TTL 3h
0.0.127.in-addr-arpa IN SOA viper.cobra.local. root.localhost. (
42 ; serial (d. adams)
2D ; refresh
4H ; retry
6W ; expiry
1W ) ; minimum

IN NS localhost.
1 IN PTR localhost.

0.0.127.in-addr.arpa. IN NS viper.cobra.local.
1.0.0.127.in-addr-arpa. IN PTR localhost
#--------------------------------------------------------------------------
Beispiel MasterzonenFile
/var/lib/master/cobra.local
$TTL 3h
cobra.local. IN SOA viper root.viper.cobra.local. (
2004111400; serial
3H ; refresh
1H ; retry
1W ; ecpiry
1D ) ; minimum
cobra.local. IN NS viper.cobra.local.
localhost.cobra.local. IN A 127.0.0.1
www.cobra.local. IN A 192.168.1.1
viper.cobra.local. IN A 192.168.1.1
ftp.cobra.local. IN A 192.168.1.1
max.cobra.local. IN A 192.168.1.1
#Die weiterne Zonen sind nach dem gleichen Muser aufgebaut
#
#hier noch die Reverselookupzone
#\var\lib\msater\1.168.192.zone
$TTL 3h
1.168.192.in-addr.arpa. IN SOA viper.cobra.local root.cobra.local. (
2004111400 ;serial
3H ; refresh
1H ; retry
1W ; expiry
1D ) ; minimum
1.168.192.in-addr.arpa. IN NS viper.cobra.local.

#1.1.168.192.in-addr.arpa. IN PTR www.cobra.local.
1.1.168.192.in-addr.arpa. IN PTR viper.cobra.local.
#1.1.168.192.in-addr.arpa. IN PTR ftp.cobra.local.
Und zum Schluss noch
#/etc/reslov.conf
search cobra.local
nameserver 192.168.1.1
 

Martin Breidenbach

Ultimate Guru
Eine .local Domäne... da schlägt wohl das Multicast DNS Problem zu.

SuSE 9.1 oder 9.2 ?

In diesem Fall lesen:

http://www.linux-club.de/viewtopic.php?t=6067
 
Oben