💡 Elevate your Linux skills with our latest course ‘Linux Fundamentals: A Complete Guide for Beginners’. Start learning today: https://www.udemy.com/course/linux-fu...
Learn about the versatile features of the "hostname" command in Linux with our in-depth guide presenting 12 practical examples.
The "hostname" command is a useful tool for altering the hostname and executing hostname-related modifications. Additionally, it provides information about DNS (Domain Name System) and NIS (Network Information Service) domain names.
💡 Key Topics Covered:
1. Understand the basics of the hostname command, hostname command syntax and its options.
2. Learn how to check the hostname of your device
3. Learn how to check the short hostname of your device
4. Learn how to change hostname of your device until reboot
5. Learn how to change hostname of your device permanently
6. Learn how to display NIS domain name
7. Learn how to change NIS domain name
8. Learn how to display network address related to your device hostname
9. Learn how to display all network address
10. Learn how to display the fully qualified domain name (FQDN) of your linux system
11. Learn how to display aliases or substitute hostname set by user
12. Learn how to get help about the hostname command
13. Learn how to print the version of the hostname command
Begin a journey into Linux expertise by diving into the intricacies of the hostname command. Subscribe now for further Linux insights and techniques to enhance your proficiency in Linux and system administration!
📜⯆ Content Index
0:00 Introduction
0:38 What is hostname Command ?
2:12 Example 1: Check the Hostname of Your Device
2:36 Example 2: Check the Short Hostname
3:45 Example 3: Change Hostname Until Reboot
4:41 Example 4: Change Hostname Permanently
5:22 Example 5: Display NIS Domain Name
5:59 Example 6: Change NIS Domain Name
6:47 Example 7: Display Related Network Addresses
7:20 Example 8: Display All Network Addresses
7:50 Example 9: Display the Fully Qualified Domain Name (FQDN) of Your Linux System
8:25 Example 10: Display Aliases Set By the Host
9:05 Example 11: Get Help About the “hostname” Command
9:41 Example 12: Get the Version of the “hostname” Command
Instructor Details
Fahmid Bin Kibria
https://linuxsimply.com/fahmid-bin-ki...
Editor Details
Reshma Raj
https://linuxsimply.com/reshma-raj/
📚 ⯆ Read the Full Article
The “hostname” Command in Linux [12 Practical Examples]
https://linuxsimply.com/hostname-comm...
📝⯆ Commands Used
What is hostname Command ?
a. man hostname
Example 1: Check the Hostname of Your Device
a. hostname
Example 2: Check the Short Hostname
a. hostname -s
b. hostname --short
Example 3: Change Hostname Until Reboot
a. sudo hostname fahmid
Example 4: Change Hostname Permanently
a. sudo hostnamectl set-hostname Ubuntu
Example 5: Display NIS Domain Name
a. hostname -y
b. hostname --yp
c. hostname --nis
Example 6: Change NIS Domain Name
a. sudo hostname -y My_NIS
Example 7: Display Related Network Addresses
a. hostname -i
b. hostname --ip-address
Example 8: Display All Network Addresses
a. hostname -I
b. hostname --all-ip-addresses
Example 9: Display the Fully Qualified Domain Name (FQDN) of Your Linux System
a. hostname --long
b. hostname --fqdn
c. hostname -f
Example 10: Display Aliases Set By the Host
a. hostname --alias
b. hostname -a
Example 11: Get Help About the “hostname” Command
a. help hostname
Example 12: Get the Version of the “hostname” Command
a. hostname --version
b. hostname -V
👉 Follow Us
Facebook: / softeko.linuxsimply
Twitter: / linuxsimply
LinkedIn: / linuxsimply
Tiktok: / linuxsimply
#linux
#ubuntu
#linuxsimply
#linuxtutorials
#command
#commandline
#hostname