LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 05-28-2004, 11:32 AM   #1
charon79m
Member
 
Registered: Oct 2003
Distribution: Just about anything... so long as it is Debain based.
Posts: 297

Rep: Reputation: 30
dhcpd - new lease every second on M$ box


I am setting up a Squid Proxy/DHCP/FTP/DNS box for a project at work. Everything works fine when I connect to the network with a Linux box, but when I connect with a M$ box I am unable to obtain and hold a DHCP lease.

What I want to happen is for boxes to be plugged into my network, get a 192.168.10 address, and use this box to route to the 192.168.3 network which is the gateway to the internet.

To make a long story short, I've got 192.168.10.0 and 192.168.3.0 running on the same switch (no VLANS for you Cisco people), and I've got two NIC's in my server.

When I watch /var/log/daemon.log I saw that what was happening is that the M$ box was getting a lease then attempting to get a new lease one second later. Mixxed in with these lease messages was a line stating "no free leases on subnet 192.168.3.0."

When I disconnect the 192.168.3 interface on my server the M$ boxes get an IP and hold it, so it looks to me like the M$ box is re-trying to get a lease on the 192.168.3 network even though I'm not handing out IP's on that network.

My /etc/dhcpd.conf file looks like this:

subnet 192.168.10.0 netmask 255.255.255.0 {
# Setup Network
# default gateway
option routers 192.168.10.1;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.10.255;

#domains
option domain-name "setup.xxxxx.com";
option domain-name-servers 192.168.10.1;

#dynamic range
range 192.168.10.100 192.168.10.254;
default-lease-time 21600;
max-lease-time 43200;
}

subnet 192.168.3.0 netmask 255.255.255.0 {
}
EOF

The only reason I have an entry for the 192.168.3.0 subnet is that hdcpd bombs if I do not.

Anyone have suggestions on how I can solve my issue through configuration of DHCPD?

Cheers,
MrKnisely
 
Old 05-28-2004, 11:45 AM   #2
charon79m
Member
 
Registered: Oct 2003
Distribution: Just about anything... so long as it is Debain based.
Posts: 297

Original Poster
Rep: Reputation: 30
Soulution or workaround... either way it's working

I added an entry for a shared network and it appears to work now. Here's the config:

shared-network LabNetwork {
# Setup Network
subnet 192.168.10.0 netmask 255.255.255.0 {
# default gateway
option routers 192.168.10.1;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.10.255;
# domains
option domain-name "setup.xxxxxxx.net";
option domain-name-servers 192.168.10.1;
# dynamic range
range 192.168.10.100 192.168.10.254;
default-lease-time 21600;
max-lease-time 43200;
}
subnet 192.168.3.0 netmask 255.255.255.0 {
}
}


As you can see, all it did was put a "shared-network { }" around it.

Cheers,
MrKnisely
 
Old 05-28-2004, 11:45 AM   #3
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
Well, it's pretty obvious that the problem is the 192.168.3.0 subnet entry. If anything tried to get an IP from that subnet, it would of course fail since there is no range information.

What happens when you remove that? What sort of problem does it cause dhcpd?
 
Old 05-28-2004, 11:47 AM   #4
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
Well, maybe not then.
 
Old 06-02-2004, 09:31 AM   #5
charon79m
Member
 
Registered: Oct 2003
Distribution: Just about anything... so long as it is Debain based.
Posts: 297

Original Poster
Rep: Reputation: 30
WOW, that was quick...

I too thought it was stupid to even mention the 192.168.3.0 network in my DHCP config, but I had to or DHCPD would bomb. It needs each subnet mentioned in the config or it won't run properly; though, I have been told by others in another forum that theirs works without mention of the 2nd subnet. If you read the man pages though it says to mention all the subnets for the daemon to work.

The reason for the strange setup is that I have these two networks sharing the same media. I have a 192.168.10.0 system plugged into the same switch/hub as a 192.168.3.0 system. The odd part is that my Linux boxes get a DHCP address on the .10 and they don't care that the .3 failed. They're just happy they got an address. It was only the M$ boxes that weren't satisfied with one address, they wanted an address from both interfaces. Odd, but not surprising given M$'s other quirks.

Thansk for the post,

MrKnisely
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
dhcpd wrong ip lease? del_gr Linux - Newbie 6 10-24-2006 10:58 AM
dhcpd subnet declaration problems in dhcpd.conf vcrispo Linux - Networking 6 07-15-2005 10:32 AM
XP Box won't connect to internet thru RH9 Box (firewall/dhcpd), it can only ping fire Rhapsodic Linux - Networking 4 07-10-2004 03:02 PM
Howto update firewall on dhcpd lease Noerr Linux - Networking 3 06-09-2004 10:36 PM
dhcpd lease question Jase Linux - Networking 2 01-31-2002 10:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration