Question: how dns works in linux?
Answer: The DNS is the default name resolution service used in UNIX (configurable option) and Windows servers. However, when the Internet was very small, hostname resolution was done using /etc/hosts file under UNIX. The hosts file is a computer file used by an operating system to map hostnames to IP addresses.