ich habe auf einem KVM-Host einen Nameserver BIND9 (192.168.1.85 intern) (192.109.24.85 extern) laufen. Alle Maschinen haben Debian Stretch installiert. Und auf dem KVM-Host läuft IPtables (Shorewall), um ein internes Netzwerk der VMs und des Hosts untereinander zu realisieren und nur bestimmte Services reinzulassen.
Der Nameserver war jetzt auch seit sechs Monaten gut erreichbar aus dem Internet. Ich hatte ihn neu konfiguriert, inzwischen aber wieder das alte Backup eingespielt. Nur seitdem ist der ns1.germany.com über DIG aus dem Internet nicht mehr erreichbar. Und somit sind Mailserver und Webserver der Domänen ebenfalls abgeklemmt.
Hier der Versuch aus dem Internet heraus:
Code: Alles auswählen
$ dig @192.109.24.85 A ns1.germany.com
; <<>> DiG 9.10.3-P4-Debian <<>> @192.109.24.85 A ns1.germany.com
; (1 server found)
;; global options: +cmd
;; connection timed out; no servers could be reached
Code: Alles auswählen
dig @192.168.1.85 A ns1.germany.com
; <<>> DiG 9.10.3-P4-Debian <<>> @192.168.1.85 A ns1.germany.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 246
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 7, ADDITIONAL: 2
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;ns1.germany.com. IN A
;; ANSWER SECTION:
ns1.germany.com. 3600 IN A 192.109.24.84
;; AUTHORITY SECTION:
germany.com. 3600 IN NS ns1.germany.com.
germany.com. 3600 IN NS ns2.he.net.
germany.com. 3600 IN NS ns2.germany.com.
germany.com. 3600 IN NS ns3.he.net.
germany.com. 3600 IN NS ns1.he.net.
germany.com. 3600 IN NS ns5.he.net.
germany.com. 3600 IN NS ns4.he.net.
;; ADDITIONAL SECTION:
ns2.germany.com. 3600 IN A 192.109.24.85
;; Query time: 0 msec
;; SERVER: 192.168.1.85#53(192.168.1.85)
;; WHEN: Sat May 11 15:46:03 CEST 2019
;; MSG SIZE rcvd: 204
Code: Alles auswählen
dig @192.109.24.85 A ns1.germany.com
; <<>> DiG 9.10.3-P4-Debian <<>> @192.109.24.85 A ns1.germany.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 48104
;; flags: qr aa rd; QUERY: 1, ANSWER: 1, AUTHORITY: 7, ADDITIONAL: 2
;; WARNING: recursion requested but not available
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;ns1.germany.com. IN A
;; ANSWER SECTION:
ns1.germany.com. 3600 IN A 192.109.24.84
;; AUTHORITY SECTION:
germany.com. 3600 IN NS ns4.he.net.
germany.com. 3600 IN NS ns2.germany.com.
germany.com. 3600 IN NS ns1.he.net.
germany.com. 3600 IN NS ns1.germany.com.
germany.com. 3600 IN NS ns3.he.net.
germany.com. 3600 IN NS ns5.he.net.
germany.com. 3600 IN NS ns2.he.net.
;; ADDITIONAL SECTION:
ns2.germany.com. 3600 IN A 192.109.24.85
;; Query time: 1 msec
;; SERVER: 192.109.24.85#53(192.109.24.85)
;; WHEN: Sat May 11 15:55:24 CEST 2019
;; MSG SIZE rcvd: 204
Code: Alles auswählen
dig @192.168.1.85 A ns1.germany.com
; <<>> DiG 9.10.3-P4-Debian <<>> @192.168.1.85 A ns1.germany.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 15997
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 7, ADDITIONAL: 2
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;ns1.germany.com. IN A
;; ANSWER SECTION:
ns1.germany.com. 3600 IN A 192.109.24.84
;; AUTHORITY SECTION:
germany.com. 3600 IN NS ns4.he.net.
germany.com. 3600 IN NS ns5.he.net.
germany.com. 3600 IN NS ns2.germany.com.
germany.com. 3600 IN NS ns2.he.net.
germany.com. 3600 IN NS ns1.he.net.
germany.com. 3600 IN NS ns3.he.net.
germany.com. 3600 IN NS ns1.germany.com.
;; ADDITIONAL SECTION:
ns2.germany.com. 3600 IN A 192.109.24.85
;; Query time: 0 msec
;; SERVER: 192.168.1.85#53(192.168.1.85)
;; WHEN: Sat May 11 15:55:58 CEST 2019
;; MSG SIZE rcvd: 204
Code: Alles auswählen
iptables -L
Chain fw-loc (1 references)
target prot opt source destination
ACCEPT udp -- anywhere 192.168.1.66 udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere 192.168.1.66 tcp dpt:domain /* DNS */
ACCEPT udp -- anywhere anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere anywhere tcp dpt:domain /* DNS */
LOG all -- anywhere anywhere LOG level info prefix "Shorewall:fw-loc:ACCEPT:"
ACCEPT all -- anywhere anywhere
Chain fw-net (1 references)
target prot opt source destination
ACCEPT udp -- anywhere anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere anywhere tcp dpt:domain /* DNS */
Chain loc-fw (1 references)
target prot opt source destination
ACCEPT udp -- 192.168.1.66 anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- 192.168.1.66 anywhere tcp dpt:domain /* DNS */
ACCEPT udp -- anywhere anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere anywhere tcp dpt:domain /* DNS */
Chain loc-net (1 references)
target prot opt source destination
ACCEPT udp -- 192.168.1.84 anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- 192.168.1.84 anywhere tcp dpt:domain /* DNS */
Chain net-fw (1 references)
target prot opt source destination
ACCEPT udp -- anywhere anywhere udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere anywhere tcp dpt:domain /* DNS */
Chain net-loc (1 references)
target prot opt source destination
ACCEPT udp -- anywhere 192.168.1.84 udp dpt:domain /* DNS */
ACCEPT tcp -- anywhere 192.168.1.84 tcp dpt:domain /* DNS */
loc steht für lokales Netz
fw steht für die Firewall auf dem Host
Ich stehe so ziemlich auf dem Schlauch, warum plötzlich die alten IPTables-Rules nicht mehr funktionieren.
Grüße
BrotherJ