A few months ago I added a list of ad server URLs to my /etc/hosts file. I edited the hosts file to take the ad server URLs and redirect them to the 127.0.0.1 loopback address on my computer. I did that in the Red Hat 9 Linux hosts file and also in the Windows 2000 hosts file. Afterwards, only about half as many advertisements appeared on most webpages. That solution worked for both Linux and Windows. The missing advertisements now appear as empty rectangles. The telephone lines in my neighborhood are only good for about 26.4 K so with less advertisements the webpages load much more quickly. It made a big difference and the Internet is now much more useable at 26.4 K.
In the /etc directory there is not only the hosts file but also the hosts.allow file and the hosts.deny file. One linux user claimed that I could have just used the hosts.deny file to block those URLs instead of using the hosts file to divert them to the loopback address of my computer. I have not tried that so I do not know if it could be used instead or not. I found a list of what URLs to block on the Mike Skallas' Ad Blocking Hosts file website. He mainly talks about how to block the adds with Windows but he also describes how to do it with Linux/Unix. Here is his website: