Ok.. a bit new to ubuntu.. but not linux.
Seems very simple. I need to ping my FQDN of host (VM) and get response back with its routable IP. I know my DNS forward and reverse IP lookup resolves via external system tests.. so this is a local host issue
used desktop GUI and it input DNS servers.. and created entries:
#root@icpdemo01:/etc/network# cat interfaces
iface lo inet loopback
auto lo
auto ens160
iface ens160
address 172.20.15.242
netmask 255.255.255.0
network 172.20.15.0
broadcast 172.20.15.255
gateway 172.20.15.1
dns-nameservers 172.20.12.100 172.20.13.100 8.8.8.8
#
root@icpdemo01:/etc/network# ping icpdemo01.ibm.aessatl.arrow.com
PING icpdemo01.ibm.aessatl.arrow.com (127.0.1.1) 56(84) bytes of data.
64 bytes from icpdemo01.ibm.aessatl.arrow.com (127.0.1.1): icmp_seq=1 ttl=64 time=0.052 ms
^C
--- icpdemo01.ibm.aessatl.arrow.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.052/0.052/0.052/0.000 ms
???? Uh.. not correct...
Google around...put entry in /etc/hosts (then move to top.. both fail)
#vi /etc/hosts
172.20.15.252 icpdemo01.ibm.aessatl.arrow.com icpdemo01
127.0.0.1 localhost
127.0.1.1 icpdemo01.ibm.aessatl.arrow.com icpdemo01
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
#
check /etc/resolv.conf because it should just.. work sudo vi /etc/resolv.conf
# This file is managed by man:systemd-resolved(8). Do not edit.
#
# This is a dynamic resolv.conf file for connecting local clients to the
# internal DNS stub resolver of systemd-resolved. This file lists all
# configured search domains.
#
# Run "systemd-resolve --status" to see details about the uplink DNS servers
# currently in use.
#
# Third party programs must not access this file directly, but only through the
# symlink at /etc/resolv.conf. To manage man:resolv.conf(5) in a different way,
# replace this symlink by a static file or a different symlink.
#
# See man:systemd-resolved.service(8) for details about the supported modes of
# operation for /etc/resolv.conf.
#nameserver 127.0.0.53
nameserver 172.20.12.100
nameserver 172.20.13.100
#
Still failing to figure out its IP..
seems like
1) Their should not be three places that it checks for DNS server.. 2) It should work.
Hoping this is simple "well.. this is how Ubuntu does name resolution in X order.. and here is fix..."
Thanks,
PS: reason for this is docker fails if it cannot detect container FQDN resolution on installation...
#TASK [check : Validating DNS server] ***************************************************************************************************************************************************************************
TASK [check : Checking Hostname is resolvable] ***************************************************************************************************************************************************************** changed: [172.20.15.252]
TASK [check : Validating Hostname is resolvable] *************************************************************************************************************************************************************** fatal: [172.20.15.252]: FAILED! => {"changed": false, "msg": "Please configure your hostname to resolve to an externally reachable IP"}
NO MORE HOSTS LEFT *********************************************************************************************************************************************************************************************
NO MORE HOSTS LEFT *********************************************************************************************************************************************************************************************
PLAY RECAP ***************************************************************************************************************************************************************************************************** 172.20.15.252 : ok=26 changed=11 unreachable=0 failed=1
Playbook run took 0 days, 0 hours, 2 minutes, 41 seconds
administrator@icpdemo01:/opt/ibm-cloud-private-ce-2.1.0.3/cluster$
#