# /etc/resolv.conf no port config?



## drmike (Aug 8, 2013)

So I am mucking with DNS tonight.

Realized something that seems obvious, but isn't.

/etc/resolv.conf settings don't support DNS on the standard port, right?

For instance:

nameserver 192.168.1.10

That won't work as:

nameserver 192.168.1.10:5353

Or will it?  Anyone know of a way to get /etc/resolv.conf to support ports?


----------



## Zach (Aug 8, 2013)

A port redirect in iptables would probably be much more simple.  There was a post on bugs.debian.org about this after some searching:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=549190

http://www.cyberciti.biz/faq/linux-port-redirection-with-iptables/


iptables -t nat -A PREROUTING -i eth0 -p udp --dport 53 -j REDIRECT --to-port 5353

I also read that OSX and OpenBSD allow this by default.


----------

