Where Is Etc Hosts File in Linux?
Contents

On Linux, you can find the hosts file under /etc/hosts. Since it’s a plain text file, you can open the hosts file using your preferred text editor. Since the hosts file is a system file, you’ll need administrative rights to save changes.

What is ETC hosts file in Linux?

The /etc/hosts is an operating system file that translate hostnames or domain names to IP addresses. This is useful for testing websites changes or the SSL setup before taking a website publicly live. … Therefore ensure that you have set static IP addresses for your Linux hosts or nodes running other operating systems.

Where is ETC hosts on Ubuntu?

The hosts file on Ubuntu (and indeed other Linux distributions) is located at /etc/hosts . As it happens, this is actually a surprisingly effective method of blocking malicious websites, and even adverts.

James H. Sterling

James H. Sterling

Environmental Science & Climate Journalist

James Sterling reports on renewable energy developments, climate policy, ecological conservation, and green tech innovations around the globe.

Share this article
Twitter Facebook Pinterest