# 8.1 Release name resolution problem



## awcroton (Jan 18, 2011)

Hi,

I am having a very strange problem with a FreeBSD 8.1 Release box that I've built to act as a firewall.

Hosts on the inside of the firewall can resolve names just fine, but the firewall itself cannot.

My /etc/resolv.conf file contains: 

```
domain="internal.aconline.eu"
nameserver="217.22.224.51"
nameserver="192.168.82.17"
```

My /etc/nsswitch.conf file contains:

```
group: compat
group_compat: nis
hosts: files dns
networks: files
passwd: compat
passwd_compat: nis
shells: files
services: compat
services_compat: nis
protocols: files
rpc: files
```


I have tried a session with nslookup as shown below:

```
[root@border ~]# nslookup
> www.google.co.uk
;; connection timed out; no servers could be reached
>
>
> server 192.168.82.17
Default server: 192.168.82.17
Address: 192.168.82.17#53
> www.google.co.uk
Server:         192.168.82.17
Address:        192.168.82.17#53

Non-authoritative answer:
www.google.co.uk        canonical name = www.google.com.
www.google.com  canonical name = www.l.google.com.
Name:   www.l.google.com
Address: 209.85.143.104
Name:   www.l.google.com
Address: 209.85.143.99
>
>
> server 217.22.224.51
Default server: 217.22.224.51
Address: 217.22.224.51#53
> www.apache.org
Server:         217.22.224.51
Address:        217.22.224.51#53

Non-authoritative answer:
Name:   www.apache.org
Address: 140.211.11.131
>
> exit
```

I do not know why the first query fails (there does not appear to be a default server ... why?), I believe that the second and third queries (specifying the servers that I identify in the /etc/resolv.conf) prove that these are real DNS servers, are prepared to resolve for me and that I do not have any firewall rules getting in the way.

Can anyone shed any light on this please?

Regards,
Alex


----------



## gordon@ (Jan 18, 2011)

Your /etc/resolv.conf looks very odd to me. Here's how I would write yours based on what you have:


```
domain internal.aconline.eu
nameserver 217.22.224.51
nameserver 192.168.82.17
```


----------



## awcroton (Jan 18, 2011)

Many thanks Gordon,

I was just on my way back here to update it with the fix that you have identified.

I must have been very tired when I thought that the file needed those quotes and equals signs 

Alex


----------

