# Bind on 11.x



## Stanks (Dec 28, 2016)

Hi,
I'm looking at following the guidance here https://doc.pfsense.org/index.php/Creating_a_DNS_Black_Hole_for_Captive_Portal_Clients to create a blackhole for a restricted BYOD WiFi network.

I'm a n00b to Linux/FreeBSD.  So I've downloaded and installed Release 11.x using nothing but defaults.  I can configure the if and the server responds to ping.  And that's about where my success ends.  Regardless of what I try, with Bind, I cannot get nslookup or dig to resolve a name.  I have nameserver 8.8.8.8 configured in resolv.conf, but I cannot get any name resolution happening.

Are there any n00b guides out there to detail how to successfully setup FreeBSD 11.x as a DNS server?

Thanks in advance.


----------



## driesm (Dec 28, 2016)

Have you added your localhost as first DNS server in resolv.conf? If you have only configured 8.8.8.8 your PC doesn't know it is running a DNS server on his own. My resolv.conf has the following entries:


```
search home.lan
nameserver 127.0.0.1
nameserver 195.130.130.11
nameserver 195.130.130.139
```
The latter two entries are DNS servers of my ISP (Telenet), where I have configured bind to cache queries from.
In your case, you could add 8.8.8.8 and 8.8.4.4 as fallback when your localhost is not providing DNS services.
But at first glance it seems you have not added your localhost (127.0.0.1) as primary DNS server in resolv.conf.

The chapter in the handbook about the Domain Name System (DNS) is a good starting point to learn: https://www.freebsd.org/doc/handbook/network-dns.html


----------

