HI
I need some help please.
I am trying to set a local DNS for my local LAN.
DNS Server on opensuse42.1.
The problem is that the server is not responding to queries …
Can anyone review my configurations and give me a tip ???
Thank s
The configurations files are like this :
Named.conf
# Copyright (c) 2001-2004 SuSE Linux AG, Nuernberg, Germany.
# All rights reserved.
#
# Author: Frank Bodammer, Lars Mueller <lmuelle@suse.de>
#
# /etc/named.conf
#
# This is a sample configuration file for the name server BIND 9. It works as
# a caching only name server without modification.
#
# A sample configuration for setting up your own domain can be found in
# /usr/share/doc/packages/bind/sample-config.
#
# A description of all available options can be found in
# /usr/share/doc/packages/bind/misc/options.
options {
# The directory statement defines the name server's working directory
directory "/var/lib/named";
# enable DNSSEC validation
#
# If BIND logs error messages about the root key being expired, you
# will need to update your keys. See https://www.isc.org/bind-keys
#
# dnssec-enable yes (default), indicates that a secure DNS service
# is being used which may be one, or more, of TSIG
# (for securing zone transfers or DDNS updates), SIG(0)
# (for securing DDNS updates) or DNSSEC.
#dnssec-enable yes;
# dnssec-validation yes (default), indicates that a resolver
# (a caching or caching-only name server) will attempt to validate
# replies from DNSSEC enabled (signed) zones. To perform this task
# the server also needs either a valid trusted-keys clause
# (containing one or more trusted-anchors or a managed-keys clause.
#dnssec-validation auto;
managed-keys-directory "/var/lib/named/dyn/";
# Write dump and statistics file to the log subdirectory. The
# pathenames are relative to the chroot jail.
dump-file "/var/log/named_dump.db";
statistics-file "/var/log/named.stats";
# The forwarders record contains a list of servers to which queries
# should be forwarded. Enable this line and modify the IP address to
# your provider's name server. Up to three servers may be listed.
forwarders {8.8.8.8; 8.8.4.4; };
# Enable the next entry to prefer usage of the name server declared in
# the forwarders section.
#forward first;
# The listen-on record contains a list of local network interfaces to
# listen on. Optionally the port can be specified. Default is to
# listen on all interfaces found on your system. The default port is
# 53.
listen-on port 53 {127.0.0.1;192.168.1.1; };
# The listen-on-v6 record enables or disables listening on IPv6
# interfaces. Allowed values are 'any' and 'none' or a list of
# addresses.
listen-on-v6 { any; };
# The next three statements may be needed if a firewall stands between
# the local server and the internet.
query-source address * port 53;
transfer-source * port 53;
notify-source * port 53;
# The allow-query record contains a list of networks or IP addresses
# to accept and deny queries from. The default is to allow queries
# from all hosts.
allow-query { 127.0.0.1;192.168.1.0/24; };
# If notify is set to yes (default), notify messages are sent to other
# name servers when the the zone data is changed. Instead of setting
# a global 'notify' statement in the 'options' section, a separate
# 'notify' can be added to each zone definition.
notify no;
disable-empty-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";
};
# To configure named's logging remove the leading '#' characters of the
# following examples.
logging {
# Log queries to a file limited to a size of 100 MB.
channel query_logging {
file "/var/log/named_querylog"
versions 3 size 100M;
print-time yes; // timestamp log entries
};
category queries {
query_logging;
};
# Or log this kind alternatively to syslog.
channel syslog_queries {
syslog user;
severity info;
};
category queries { syslog_queries; };
# Log general name server errors to syslog.
channel syslog_errors {
syslog user;
severity error;
};
category default { syslog_errors; };
# Don't log lame server messages.
category lame-servers { null; };
};
# The following zone definitions don't need any modification. The first one
# is the definition of the root name servers. The second one defines
# localhost while the third defines the reverse lookup for localhost.
zone "." in {
type hint;
file "root.hint";
};
zone "localhost" in {
type master;
file "localhost.zone";
};
zone "0.0.127.in-addr.arpa" in {
type master;
file "127.0.0.zone";
};
zone "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 "127.0.0.zone";
};
zone "umbrella-fw.local" in {
type master;
file "master/umbrella-internal-lan-fw.zone";
};
zone "umbrella-rev.zone" in {
type master;
file "master/umbrella-internal-lan-fw.zone";
};
# Include the meta include file generated by createNamedConfInclude. This
# includes all files as configured in NAMED_CONF_INCLUDE_FILES from
# /etc/sysconfig/named
include "/etc/named.conf.include";
# You can insert further zone records for your own domains below or create
# single files in /etc/named.d/ and add the file names to
# NAMED_CONF_INCLUDE_FILES.
# See /usr/share/doc/packages/bind/README.SUSE for more details.
My zone files are like this :
$TTL 1W
@ IN SOA ns1.umbrella.local. root.umbrella.local. (
2016103019 ; serial (d. adams)
2D ; refresh
4H ; retry
6W ; expiry
1W ) ; minimum
@ NS ns1.umbrella.local.
@ NS ns2.umbrella.local.
@ IN A 127.0.0.1
@ IN AAAA ::1
;##############################################################
;## Phisical / Local Hosts ##
;##############################################################
hades IN A 192.168.1.8
hv IN A 192.168.1.252
hv-ilo IN A 192.168.1.250
;##############################################################
;## Virtual / Local Hosts ##
;##############################################################
ns1.umbrella.local IN A 192.168.1.1
;ns1 CNAME ns1.umbrella.local.
ns2.umbrella.local IN A 192.168.1.2
;ns2 CNAME ns2.umbrella.local.
dc IN A 192.168.1.230
The reverse zone file
$TTL 1W
@ IN SOA ns1.umbrella.local. root.umbrella.local. (
2016103019 ; serial (d. adams)
2D ; refresh
4H ; retry
6W ; expiry
1W ) ; minimum
IN NS ns1.umbrella.local.
IN NS ns2.umbrella.local.
;##############################################################
;## Phisical / Local Hosts ##
;##############################################################
8 IN PTR hades.umbrella.local.
9 IN PTR srv.umbrella.local.
250 IN PTR ilo-hv.umbrella.local.
252 IN PTR hv.umbrella.local.
;##############################################################
;## Virtual / Local Hosts ##
;##############################################################
1 IN PTR ns1.umbrella.local.
2 IN PTR ns2.umbrella.local.
230 IN PTR dc.umbrella.local.
resolv.conf
### /etc/resolv.conf file autogenerated by netconfig!
#
# Before you change this file manually, consider to define the
# static DNS configuration using the following variables in the
# /etc/sysconfig/network/config file:
# NETCONFIG_DNS_STATIC_SEARCHLIST
# NETCONFIG_DNS_STATIC_SERVERS
# NETCONFIG_DNS_FORWARDER
# or disable DNS configuration updates via netconfig by setting:
# NETCONFIG_DNS_POLICY=''
#
# See also the netconfig(8) manual page and other documentation.
#
# Note: Manual change of this file disables netconfig too, but
# may get lost when this file contains comments or empty lines
# only, the netconfig settings are same with settings in this
# file and in case of a "netconfig update -f" call.
#
### Please remove (at least) this line when you modify the file!
search umbrella
nameserver 127.0.0.1
ns1:~ # netstat -tapnl | grep named
tcp 0 0 192.168.1.1:53 0.0.0.0:* LISTEN 12794/named
tcp 0 0 127.0.0.1:53 0.0.0.0:* LISTEN 12794/named
tcp 0 0 127.0.0.1:953 0.0.0.0:* LISTEN 12794/named
tcp 0 0 :::53 :::* LISTEN 12794/named
tcp 0 0 ::1:953 :::* LISTEN 12794/named
ns1:~ #
ifconfig
ns1:~ # ifconfig
eth0 Link encap:Ethernet HWaddr 00:0C:29:57:1F:0E
inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe57:1f0e/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:268 errors:0 dropped:7 overruns:0 frame:0
TX packets:161 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:21212 (20.7 Kb) TX bytes:41497 (40.5 Kb)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:30654 errors:0 dropped:0 overruns:0 frame:0
TX packets:30654 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:2693228 (2.5 Mb) TX bytes:2693228 (2.5 Mb)
ns1:~ #
result of a dig
ns1:~ # dig hades.umbrella.local 127.0.0.1
; <<>> DiG 9.9.9-P1 <<>> hades.umbrella.local 127.0.0.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 63411
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;hades.umbrella.local. IN A
;; AUTHORITY SECTION:
. 1423 IN SOA a.root-servers.net. nstld.verisign-grs.com. 2016103101 1800 900 604800 86400
;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Oct 31 20:43:13 WET 2016
;; MSG SIZE rcvd: 124
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 46840
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;127.0.0.1. IN A
;; AUTHORITY SECTION:
. 896 IN SOA a.root-servers.net. nstld.verisign-grs.com. 2016103101 1800 900 604800 86400
;; Query time: 64 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Oct 31 20:43:13 WET 2016
;; MSG SIZE rcvd: 113
ns1:~ #
ns1:~ # dig hades
; <<>> DiG 9.9.9-P1 <<>> hades
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 7224
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;hades. IN A
;; AUTHORITY SECTION:
. 1772 IN SOA a.root-servers.net. nstld.verisign-grs.com. 2016103101 1800 900 604800 86400
;; Query time: 0 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Oct 31 20:36:11 WET 2016
;; MSG SIZE rcvd: 109
ns1:~ # dig hades 192.168.1.1
; <<>> DiG 9.9.9-P1 <<>> hades 192.168.1.1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 14901
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;hades. IN A
;; AUTHORITY SECTION:
. 1317 IN SOA a.root-servers.net. nstld.verisign-grs.com. 2016103101 1800 900 604800 86400
;; Query time: 1 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Oct 31 20:43:46 WET 2016
;; MSG SIZE rcvd: 109
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 56746
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;192.168.1.1. IN A
;; AUTHORITY SECTION:
. 1796 IN SOA a.root-servers.net. nstld.verisign-grs.com. 2016103101 1800 900 604800 86400
;; Query time: 62 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Oct 31 20:43:46 WET 2016
;; MSG SIZE rcvd: 115
Status of the named process
ns1:~ # ps -ax | grep named
12794 ? Ssl 0:00 /usr/sbin/named -t /var/lib/named -u named
18058 pts/0 S+ 0:00 grep --color=auto named
ns1:~ #