AndyBauer
Contributor
Contributor

Host Profile compliance - did not find mapping for ip X.X.X.X in /etc/hosts file on the host

Hey guys,

today another challenge. I have deployed host profiles in my environment and everything works fine, great feature!

There is only one little leak, that prevents my hosts get fully compliant:

Each host (except the source-host for the profile) reporting not to be compliant because of " did not find mapping for ip X.X.X.X in /etc/hosts file on the host " message.

All esx have a local hosts file with the same content (List of all hosts and the according ip adress).

Now every hosts says it cannot find mapping for itself.

Example:

Host vm020 is the reference host - everything good host is compliant

Host vm021 (IP-Adress 10.0.0.10) is not compliant with message "did not find mapping for ip 10.0.0.10 in /etc/hosts file on the host"

Host vm022 (IP-Adress 10.0.0.11) is not compliant with message "did not find mapping for ip 10.0.0.11 in /etc/hosts file on the host" 

and so on....

Any hints?

Reply
0 Kudos
tomtom901
Commander
Commander

It should also have itself in the hosts file, in example:

192.168.1.13 spartacus.vcaplab.local spartacus

Reply
0 Kudos
AndyBauer
Contributor
Contributor

Hi Tomtom,

thats given:

Following content of hosts an all of my esx-server

hosts:

# Do not remove the following line, or various programs

# that require network functionality will fail.

127.0.0.1       localhost.localdomain localhost

::1             localhost.localdomain localhost

10.0.0.10     pfo-vm020

10.0.0.11     pfo-vm021

10.0.0.12     pfo-vm022

.

.

.

and so on.

Reply
0 Kudos
tomtom901
Commander
Commander

Hm, perhaps it needs the local host entry to be on the third line, I'll test this later today.

Reply
0 Kudos
AndyBauer
Contributor
Contributor

Hi all,

I have tried in my test environment and found the same issue.

The host profile applies the new hosts file but hosts still not get compliant.

Unbenannt-3.jpg

Reply
0 Kudos