In Ubuntu 10.04 and most Linux distro’s you can edit the hosts file directly in the terminal. Also for more info on editing your Hosts file, check out The Geek’s article on how to create a shortcut to quickly edit your Hosts file. We also were not able to get to it in Google Chrome… (check notes at the end). Now notice if we try to access Facebook in IE we can’t get to the page.
Now let’s look at accessing the hosts files in the different operating systems… They can be separated by a space, but for ease of reading are typically separated by one or two tabs. The first part will be the location to redirect the address to, the second part will be the address that you will want to redirect, and the third part is the comment. We can use that for the basic example for the typical syntax. Most hosts files will have several entries for loopback. The syntax stays mostly the same across all platforms. Microsoft kept the hosts file alive in Windows networking which is why it varies very little whether used in Windows, macOS, or Linux. hosts files would be massive documents used to aide the network name resolution. They were used to resolve hosts names before DNS. Hosts files have been in use since ARPANET. Sometimes because of an attack or prank, and others so that you can simply and freely control access to websites and network traffic. On occasion you will need to edit the hosts file on your machine.