Unix

Hostname Command in Unix

Hostname command shows the name of the system or server you are logged into. Hostname is used to display the system's DNS name, and to display or set its hostname or NIS (Network Information Services) domain name.
The syntax of hostname command is

The options of the host name command are
Examples of host name Command

  • Print IP address of the system.  


  • Print the domain name. 
Powered by Blogger.