Hello Daniweb Members,
I have just finished setting up a simple DNS Server using BIND9 on Ubuntu, the main reason I did this was that it should theoretically make browsing faster as it doesn't need to send requests to my ISPs servers which are appeoximately 241 miles away... or at least that is what I said to my brother.
Admittedly it shall make it ever so slightly quicker, but it would be negligable... the main reason is so I can block specific websites. My main idea (I should point out I am new to setting up DNS servers) was to create a zone file which shall take the domain and change the IP to a local one which is running a Web Server, so that I can put up a 'block' page etc. This obviously isn't the most efficient way of doing it, but I am hoping this DNS spoofing shall be good enough.
I am not entirely sure how I should setup the required files, I've looked at many tutorials online however I haven't been able to complete this action with any success.
In my named.conf.local file I have:
zone "domainToBlock.com" in { type master ; file "zoneFiles/domainToBlock" ; } ;
And then in the domainToBlock file I have nothing... this is where I get stuck. As this is an internal server I do not have a domain for it, and the hostname is simply AH-Server. For the zone file I need to put in a domain name but I don't know what to use, would it be the LAN IP (192.168.1.10) or would it be the localhost. For the new A record, can I just use localhost/LAN IP as the DNS server is running on the same hardware as the Web Server?
If anyone could please help me, mainly with working out what domain name I should be using, and how to configure the zone file to point to the local web server.
Thank you