Page tree
Skip to end of metadata
Go to start of metadata

The "Hosts file" format can severely impact the Diagnostics Agent, the SAP Host Agent, connectivity between Managed Systems and Solution Manager ALM

More information on the note : 2926115 and note : 611361

The location of the "Hosts file's" is the following:

  • On Unix/Linux: /etc/hosts
  • On Windows: C:\Windows\System32\drivers\etc\hosts

# Example of hosts files with correct format for Outside Discovery

#IP                                            Full Qualified Domain Name                                      Hostname                                              myPhysicalHost                                                myVirtualHost                                                myLogicalHost

1st position: IP address 

2nd position: FQDN (full qualified domain name)

3rd position: short hostname


  • For "Logical hosts" on the physical/virtual host, follow the instruction on the SAP Note 962955.
  • All mentioned "IP addresses", "FQDNs" and "hostnames" have to be unique in the host file to make it readable for SAP Server, you can't have two times the same entry.

  • Two different FQDNs in one line will also create problem in the hosts file to make it readable for SAP Server.

  • For RedHat and Suse Linux Os /etc/hosts "Example line" format specificity :

    •   localhost localhost.localdomain localhost4 localhost4.localdomain4
    • ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

    This format is incorrect because of its 2 FQDN's and also its incorrect ordering (by default)

    Please correct the format as following or simply removing the two "Example lines" to avoid any network connectivity issues

    • ##  localhost.localdomain localhost
    • ##::1         localhost.localdomain localhost 

  • Modification in the "hosts" file will require an OS restart, or at least a restart of the Network service, Diagnostics Agent and the SAP Host Agent.
    • Regarding the restart of the Network Service:
      • On Unix/Linux: restart /etc/init.d/networking
      • On Windows: restart the network service

For more information about the /etc/hosts file Standard Format definition please follow guideline in Guided Answer or FAQ

Please note that if one line doesn't have this specific format, the IP resolution and the "hosts file" will have a problem to work correctly. See Note : 2926115

The "hosts" file standard format is defined as per RFC952 (Hosts Table Convention).

  • The RFC for protocols specify these labels must only contain the ASCII letters a through z (in a case-insensitive manner), the digits 0 through 9, and the hyphen-minus character ('-'). The original specification of hostnames in RFC 952 disallowed labels starting with a digit or with a hyphen character and end with a hyphen. However, a subsequent specification (RFC 1123) permits hostname labels to start with digits. No other symbols, punctuation characters, or whitespace are permitted. Internationalized domain names are stored in the Domain Name System as ASCII strings using Punycode transcription.[4]

Following the information in MCSA/MCSE 70-254: Monitoring and Troubleshooting Network Activity

  • Hosts files are very effective in small environments with a limited number of hosts; however, the vast number of Internet resources led to the development of DNS.
  • No labels