Today, I tried changing the hosts file. The result is the hosts file is now ignored. Can you help me get it working again?
STEPS
- Loggedin as root user in terminal
- Created a file containing what I wanted in the hosts file as ~/hosts This file contained a copy of what was in the hosts file, with a long long list of domains like this 127.0.0.1 domain.tlc My intention was to block ads for all those domains.
- Copied /private/etc/hosts to /private/etc/hostsHOTROLL (to keep a backup of the hosts file)
- Deleted /private/etc/hosts
- Copied ~/hosts /private/etc/hosts
- ran from command line as root user: killall -HUP mDNSResponder
- Deleted /private/etc/hosts
- Copied /private/etc/hostsHOTROLL to /private/etc/hosts
- an from command line as root user: killall -HUP mDNSResponder
Here is what is in my hosts file:
Code:
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
10.0.0.16 busterboss.fortress200g.work
10.0.0.17 rmw.fortress200g.work
10.0.0.15 mondostretch.fortress200g.work
10.0.0.8 debian-bups-500g.fortress.work
I can ping 10.0.0.15
When I ping mondostretch.fortress200g.work, it is resolving to the ip on the name server where it is registered. It needs to resolve to 10.0.0.15, which is an ip on my lan, not reachable from the internet.
Any assistance you can provide will be immensely appreciated.
Thank you.
Last edited: