DB2 installation issue : The hostname is invalid

During DB2 installation you might get error The hostname is invalid. We get this error if your hostname is not properly configured and mapped to an IP Address which is reachable.

While performing DB2 installation using db2setup command you might get below error screen.

Same solution is valid for error during installation with db2_install command.


To fix this first check your server hostname by executing hostname command

Ping your hostname to check if it responding locally, you will get ping failure.

ping <hostname>

Check /etc/hosts file for mapping for hostname with ip address.

cat /etc/hosts

Correct hostname and IP address mapping in /etc/hosts file by editing /etc/hosts file using vi or any other editor.

After correcting /etc/hosts file, ping your hostname to see if it is responding.

This should fix the issue and you can continue with installation.



If you liked this blog and interested in knowing more about DB2, please subscribe by clicking on Subscribe to ChoudharySumit.com by Email.

2 comments:

  1. I was getting this error! Now it's resolved.
    Thanks for the info!

    ReplyDelete