Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   simple home dns, dhcp server. (http://www.linux-archive.org/debian-user/187334-simple-home-dns-dhcp-server.html)

Lachlan 11-04-2008 03:34 AM

simple home dns, dhcp server.
 
i been have tremendous trouble getting my network to see hostnames and
and other pc's. it will see everything randomly one day and then be
missing the next.

my idea to fix this is to have an old laptop (old as in i upgraded 3
months ago, running lenny but hasn't been updated since august) that
i'm thinking could be used as the network dhcp instead of my modem
(which i'm thinking is half the problem) this server would connect to
the internet with the modem and then give each system on the network a
dhcp address as well as provide an internel dns.

i've looked at guides that use bind 9 but it doesn't make a whole lot
of sense for what i'm trying to achieve. at least as far as i'm aware.
networking isn't my forte.

so is it possible to use a single nic laptop as a dhcp/dns server for
an internal home network?

if that is possible would moving my apache server to the same laptop
cause issues with the dhcp/dns config?

cheers


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

"Douglas A. Tutty" 11-04-2008 03:50 AM

simple home dns, dhcp server.
 
On Tue, Nov 04, 2008 at 02:34:58PM +1000, Lachlan wrote:

> my idea to fix this is to have an old laptop (old as in i upgraded 3
> months ago, running lenny but hasn't been updated since august) that
> i'm thinking could be used as the network dhcp instead of my modem
> (which i'm thinking is half the problem) this server would connect to
> the internet with the modem and then give each system on the network a
> dhcp address as well as provide an internel dns.
>
> i've looked at guides that use bind 9 but it doesn't make a whole lot
> of sense for what i'm trying to achieve. at least as far as i'm aware.
> networking isn't my forte.
>
> so is it possible to use a single nic laptop as a dhcp/dns server for
> an internal home network?
>
> if that is possible would moving my apache server to the same laptop
> cause issues with the dhcp/dns config?

look at dnsmasq. I don't use the dhcp part, but it works just fine
out-of-the-box for dns. The box that connects to my (dialup) modem runs
dnsmasq and has all my hosts in /etc/hosts. The other boxes on my
network know their own hostname, IP address, and the IP of the box
running dnsmasq as the DNS server.

DHCP has seemed like overkill for me where each box is dedicated to
something specific (i.e. the main box, the print/backup/terminal server,
the OpenBSD box; with coresponding hostnames of titan, rocky (noisy
fan), and reliant (14 years old, never a problem).


Doug.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Lachlan 11-04-2008 04:08 AM

simple home dns, dhcp server.
 
2008/11/4 Douglas A. Tutty <dtutty@vianet.ca>:
> On Tue, Nov 04, 2008 at 02:34:58PM +1000, Lachlan wrote:
>
>> my idea to fix this is to have an old laptop (old as in i upgraded 3
>> months ago, running lenny but hasn't been updated since august) that
>> i'm thinking could be used as the network dhcp instead of my modem
>> (which i'm thinking is half the problem) this server would connect to
>> the internet with the modem and then give each system on the network a
>> dhcp address as well as provide an internel dns.
>>
>> i've looked at guides that use bind 9 but it doesn't make a whole lot
>> of sense for what i'm trying to achieve. at least as far as i'm aware.
>> networking isn't my forte.
>>
>> so is it possible to use a single nic laptop as a dhcp/dns server for
>> an internal home network?
>>
>> if that is possible would moving my apache server to the same laptop
>> cause issues with the dhcp/dns config?
>
> look at dnsmasq. I don't use the dhcp part, but it works just fine
> out-of-the-box for dns. The box that connects to my (dialup) modem runs
> dnsmasq and has all my hosts in /etc/hosts. The other boxes on my
> network know their own hostname, IP address, and the IP of the box
> running dnsmasq as the DNS server.
>
> DHCP has seemed like overkill for me where each box is dedicated to
> something specific (i.e. the main box, the print/backup/terminal server,
> the OpenBSD box; with coresponding hostnames of titan, rocky (noisy
> fan), and reliant (14 years old, never a problem).
>

thanks, this looks like the perfect package. i'll give it a whirl now.
i'll follow the wiki page and here's the link if anyone else is doing
something similar

http://wiki.debian.org/HowTo/dnsmasq

>
> Doug.
>
>
> --
> To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
>
>


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

"H.S." 11-04-2008 04:10 AM

simple home dns, dhcp server.
 
Douglas A. Tutty wrote:
> On Tue, Nov 04, 2008 at 02:34:58PM +1000, Lachlan wrote:
>
>> my idea to fix this is to have an old laptop (old as in i upgraded 3
>> months ago, running lenny but hasn't been updated since august) that
>> i'm thinking could be used as the network dhcp instead of my modem
>> (which i'm thinking is half the problem) this server would connect to
>> the internet with the modem and then give each system on the network a
>> dhcp address as well as provide an internel dns.
>>
>> i've looked at guides that use bind 9 but it doesn't make a whole lot
>> of sense for what i'm trying to achieve. at least as far as i'm aware.
>> networking isn't my forte.
>>
>> so is it possible to use a single nic laptop as a dhcp/dns server for
>> an internal home network?
>>
>> if that is possible would moving my apache server to the same laptop
>> cause issues with the dhcp/dns config?
>
> look at dnsmasq. I don't use the dhcp part, but it works just fine
> out-of-the-box for dns. The box that connects to my (dialup) modem runs
> dnsmasq and has all my hosts in /etc/hosts. The other boxes on my
> network know their own hostname, IP address, and the IP of the box
> running dnsmasq as the DNS server.
>
> DHCP has seemed like overkill for me where each box is dedicated to
> something specific (i.e. the main box, the print/backup/terminal server,
> the OpenBSD box; with coresponding hostnames of titan, rocky (noisy
> fan), and reliant (14 years old, never a problem).
>
>
> Doug.


I also use dnsmasq. I also use it to give DHCP addresses to the clients
on my home network. If find this feature very useful since all I need to
do is to give hostname to a computer and make it a DHCP client. The
dnsmasq server, in which I specify which hostname (with mac address)
should ge what IP addresses, then gives the relevant IP address to that
computer. Very neat and easy.

The computer that runs dnsmasq is connected to my ADSL modem. That
computer makes the pppoe connection and my modem works in a bridge mode.
So basically the modem is out of the picture for anything other than the
internet connection.


--

Please reply to this list only. I read this list on its corresponding
newsgroup on gmane.org. Replies sent to my email address are just
filtered to a folder in my mailbox and get periodically deleted without
ever having been read.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Tzafrir Cohen 11-04-2008 08:50 AM

simple home dns, dhcp server.
 
On Mon, Nov 03, 2008 at 11:50:18PM -0500, Douglas A. Tutty wrote:

> look at dnsmasq. I don't use the dhcp part, but it works just fine
> out-of-the-box for dns. The box that connects to my (dialup) modem runs
> dnsmasq and has all my hosts in /etc/hosts. The other boxes on my
> network know their own hostname, IP address, and the IP of the box
> running dnsmasq as the DNS server.

An /etc/ethers file to allocate addresses can also be handy (be sure to
set 'use-ethers')

arpwatch is also handy . E.g. for the time we had a strange "network
problem" where almost nothing worked. After a while I noticed a message
from arpwatch of collisions for the IP address of the server that runs
dnsmasq.

A bit of tracing, shouting, and problem solved.

>
> DHCP has seemed like overkill for me where each box is dedicated to
> something specific (i.e. the main box, the print/backup/terminal server,
> the OpenBSD box; with coresponding hostnames of titan, rocky (noisy
> fan), and reliant (14 years old, never a problem).

DHCP is simple and it works. It helps if you want to allow someone else
to just get an IP address. It allows all sorts of things like PXE
installation to work.

In my setup it would be:

/etc/ethers:

00:11:22:33:44:55:66 titan
00:11:22:33:44:55:77 rocky
00:11:22:33:44:AA:BB reliant

/etc/hosts

10.0.3.5 titan
10.0.3.6 rocky
10.0.3.6 reliant

--
Tzafrir Cohen | tzafrir@jabber.org | VIM is
http://tzafrir.org.il | | a Mutt's
tzafrir@cohens.org.il | | best
ICQ# 16849754 | | friend


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


All times are GMT. The time now is 09:19 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.