Configure Hostnames and Name Resolution Flashcards
1
Q
How do you display current hostname?
A
hostname
2
Q
How do you display hostname status?
A
hostnamectl status
3
Q
How do you change the hostname and hostname configuration file?
A
hostnamectl hostname <domain></domain>
4
Q
How do you look up the ip address of a server?
A
getent hosts <server></server>
5
Q
What command do you update the file to add a server to access an IP address
A
vim /etc/hosts
6
Q
What command do you use to view the hostname at network start?
A
cat /etc/hostname
7
Q
What command do you use to look up the IP address of a server?
A
getent hosts class
8
Q
What command do you use to ping a server?
A
ping -c3 <server></server>