I have given the below entries in /etc/hosts :
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
#127.0.0.1 localhost.localdomain localhost
# Public
192.168.56.101 node1.localdomain node1
192.168.56.102 node2.localdomain node2
# Private
192.168.1.101 node1-priv.localdomain node1-priv
192.168.1.102 node2-priv.localdomain node2-priv
# Virtual
192.168.56.111 node1-vip.localdomain node1-vip
192.168.56.112 node2-vip.localdomain node2-vip
# SCAN
192.168.56.121 node-scan.localdomain node-scan
192.168.56.122 node-scan.localdomain node-scan
192.168.56.123 node-scan.localdomain node-scan
/etc/resolv.conf holding the below entries :
search localdomain
nameserver 192.168.56.1
DNSMASQ service is active and running :
[root@node2 network-scripts]# systemctl status dnsmasq
● dnsmasq.service - DNS caching server.
Loaded: loaded (/usr/lib/systemd/system/dnsmasq.service; enabled; vendor preset: disabled)
Active: active (running) since Sun 2021-01-24 13:17:51 IST; 12min ago
Main PID: 27061 (dnsmasq)
CGroup: /system.slice/dnsmasq.service
└─27061 /usr/sbin/dnsmasq -k
Jan 24 13:17:51 node2.localdomain systemd[1]: Stopped DNS caching server..
Jan 24 13:17:51 node2.localdomain systemd[1]: Started DNS caching server..
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: started, version 2.76 cachesize 150
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: compile time options: IPv6 GNU-getopt DBus no-i18n IDN DHCP DHCPv6 no-Lua TF...notify
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: using local addresses only for domain localdomain
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: reading /etc/resolv.conf
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: using local addresses only for domain localdomain
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: using nameserver 192.168.56.1#53
Jan 24 13:17:51 node2.localdomain dnsmasq[27061]: read /etc/hosts - 11 addresses
Hint: Some lines were ellipsized, use -l to show in full.
Below is the configuration of my IPs :
[root@node2 network-scripts]# ifconfig
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
ether 08:00:27:55:df:5d txqueuelen 1000 (Ethernet)
RX packets 1517959 bytes 1746410780 (1.6 GiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 314566 bytes 19078121 (18.1 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
enp0s8: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.56.102 netmask 255.255.255.0 broadcast 192.168.56.255
inet6 fe80::af50:c617:57b:b9b9 prefixlen 64 scopeid 0x20<link>
ether 08:00:27:86:62:18 txqueuelen 1000 (Ethernet)
RX packets 191 bytes 18075 (17.6 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 607 bytes 60723 (59.2 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
enp0s9: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.102 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80:
ether 08:00:27:47:49:50 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 321 bytes 42936 (41.9 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 0 (Local Loopback)
RX packets 190 bytes 16195 (15.8 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 190 bytes 16195 (15.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
virbr0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 192.168.122.1 netmask 255.255.255.0 broadcast 192.168.122.255
ether 52:54:00:56:2d:c6 txqueuelen 0 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
Still I am unable to nslookup my host and scan entries :
[root@node2 network-scripts]# nslookup node2
;; connection timed out; no servers could be reached
[root@node2 network-scripts]# nslookup node-scan
;; connection timed out; no servers could be reached
I am still stuck in here. Request your help to proceed further