[martin@martin ~]$ ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp0s25: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 90:e6:ba:10:df:80 brd ff:ff:ff:ff:ff:ff
inet 10.0.20.11/23 brd 10.0.21.255 scope global enp0s25
valid_lft forever preferred_lft forever
inet6 2001:67c:26f8:1:92e6:baff:fe10:df80/64 scope global dynamic
valid_lft 2592003sec preferred_lft 604803sec
inet6 fe80::92e6:baff:fe10:df80/64 scope link
valid_lft forever preferred_lft forever
3: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1492 qdisc pfifo_fast state UNKNOWN qlen 3
link/ppp
inet 193.192.37.28 peer 10.0.128.1/32 scope global ppp0
valid_lft forever preferred_lft forever
[martin@martin ~]$ ip addr show | grep -E -o "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\/[0-9]{1,2}"
127.0.0.1/8
10.0.20.11/23
10.0.128.1/32
[martin@martin ~]$
[root@guestdns ~]# cat /etc/named.conf
//
// named.conf
//
// Provided by Red Hat bind package to configure the ISC BIND named(8) DNS
// server as a caching only nameserver (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
options {
listen-on port 53 { 94.158.46.3; 127.0.0.1; };
listen-on-v6 port 53 { ::1; };
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
memstatistics-file "/var/named/data/named_mem_stats.txt";
allow-query { 10.0.0.0/12; 193.192.36.0/23; 94.158.36.0/20; };
recursion yes;
};
logging {
channel default_debug {
file "data/named.run";
severity dynamic;
};
};
zone "." IN {
type master;
file "named.ca";
};
include "/etc/named.rfc1912.zones";
include "/etc/named.root.key";
zone "lds.ua" IN {
type slave;
file "slaves/lds.ua.dns";
masters { 193.192.36.3; 94.158.46.150; };
};
zone "lds.net.ua" IN {
type slave;
file "slaves/lds.net.ua.dns";
masters { 193.192.36.3; 94.158.46.150; };
};
[root@guestdns ~]# cat /var/named/named.ca
$TTL 60
@ IN SOA @ hostmaster (
0 ; serial
60 ; refresh
5 ; retry
60 ; expire
60 ) ; minimum
NS @
A 94.158.46.3
* A 94.158.46.3
[root@guestdns ~]#