|
Home > Archive > Linux Debian support > October 2005 > DHCP vs. DNS
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Niki Kovacs 2005-10-04, 5:48 pm |
| Hi,
I just setup a DHCP server on the 'main' box of our small LAN.
Unfortunately, there's no DSL here, so we all share a dialup connection via
IP Masquerading.
Up until now, every machine had a static configuration, but I wanted to do
things more elegantly, so I opted for DHCP. One small problem remains,
though.
The main machine is connected OK (via pon). And all of the clients can ping
ip addresses on the internet. Only name resolution fails for the clients.
Sure, I could manually add a DNS entry (213.36.80.1, that's Tiscali's
primary DNS server) to every client's /etc/resolv.conf. Only I thought that
there _must_ be some way to configure it centrally on the main box'
dhcpd.conf.
I waded through the DHCP docs, but couldn't succeed in setting it up. (I
asked on irc.debian.org#debian after that, but got only a curt RTFM...))
Any ideas?
Niki Kovacs
--
I'm not as think as you stoned I am.
| |
| Bernhard Kastner 2005-10-04, 5:48 pm |
| Niki Kovacs wrote:
> Hi,
> Sure, I could manually add a DNS entry (213.36.80.1, that's Tiscali's
> primary DNS server) to every client's /etc/resolv.conf. Only I thought that
> there _must_ be some way to configure it centrally on the main box'
> dhcpd.conf.
>
> I waded through the DHCP docs, but couldn't succeed in setting it up. (I
> asked on irc.debian.org#debian after that, but got only a curt RTFM...))
well, rtfm ;)
there's an option called "option domain-name-servers" which is passed to
the DHCP-Client when getting the IP. This option should add the
DNS-Adresses to your client's /etc/resolv.conf or windows-config or
whatever...
option domain-name-servers ns1.abc.org, ns2.abc.org
man dhcpd.conf
hth
Bernhard
| |
| Niki Kovacs 2005-10-04, 5:48 pm |
| Bernhard Kastner wrote:
> well, rtfm ;)
> there's an option called "option domain-name-servers" which is passed to
> the_DHCP-Client_when_getting_the_IP._This_option_should_add_the
> DNS-Adresses to your client's /etc/resolv.conf or windows-config or
> whatever...
>
> option domain-name-servers ns1.abc.org, ns2.abc.org
Well, I found this option, and I also tried it. Something must have gone
wrong, then. I'll get a coffee, and then give it another shot.
Thanks,
Niki Kovacs
--
I'm not as think as you stoned I am.
| |
| Bernhard Kastner 2005-10-04, 5:48 pm |
| Niki Kovacs wrote:
>
> Well, I found this option, and I also tried it. Something must have gone
> wrong, then. I'll get a coffee, and then give it another shot.
>
DHCP is really, *really* exact about any punctuation, so double-check
commas and dots. Also don't forget the option routers (but this must
already been set correctly, because your clients can ping external IPs).
See http://rootr.net/man/man/dhcp-options/5 (man dhcp-options) for more
infos.
| |
| Niki Kovacs 2005-10-05, 2:46 am |
| Bernhard Kastner wrote:
>
> DHCP is really, really exact about any punctuation, so double-check
> commas and dots. Also don't forget the option routers (but this must
> already been set correctly, because your clients can ping external IPs).
Getting another coffee worked. option domain-name-servers, and hey, it
rocks. Every /etc/resolv.conf suddenly knows about it.
Niki
--
I'm not as think as you stoned I am.
|
|
|
|
|