Can't stop questioning!


Tuyen D. Le September 03, 2023 [Server] #dns


  1. Load Distribution: Has web cache, saves frequently accessed information
  2. Domain:, Hostname:
  3. FQDN: Fully qualified domain name
  4. Types of DNS: A, MX, NS, Alias
  5. DNS Zone: record includes its name and IP address

Change DNS server Ubuntu 14.04

# >> Persistent
$ sudo nano /etc/network/interfaces
#Below iface eth0 inet static add the following line:
dns-nameservers	#This will use Google's DNS servers.

# Note: as chaos says, you can also edit /etc/resolv.conf 
# but these changes will be overwritten on reobot.
# >> Temprary
$ vi /etc/resolv.conf

# Restart your network
$ sudo /etc/init.d/networking restart		

Show DNS server after Reboot

nmcli device show <interfacename> | grep IP4.DNS	# Ubuntu >= 15
nmcli dev list iface <interfacename> | grep IP4		# Ubuntu <= 14

Assign DNS record

$ sudo vi /etc/hosts       mypc
$ sudo service network-manager restart
# OR 	
$ sudo service networking restart


ldtuyen@pc:~$ apt-cache search nslookup
# dnsutils - Clients provided with BIND
# knot-dnsutils - Clients provided with Knot DNS (kdig, knslookup, knsupdate)
# libbot-basicbot-pluggable-perl - extended simple IRC bot for pluggable modules
# libnet-nslookup-perl - simple DNS lookup module for perl
ldtuyen@pc:~$ sudo apt-get install dnsutils