LinuxQuestions.org
Register a domain and help support LQ
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-17-2005, 01:39 AM   #1
joperami
LQ Newbie
 
Registered: May 2005
Location: Guayaquil - Ecuador
Distribution: Fedora
Posts: 1

Rep: Reputation: 0
Question Linux DHCP server


i would like to know if i have one interface with 2 or more ip address of diferent networks, can it be a DHCP server for the two or more networks it is conected to ?

I had configured it with only one ip address to only one network but i its not enough.
 
Old 05-17-2005, 06:53 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,819

Rep: Reputation: 727Reputation: 727Reputation: 727Reputation: 727Reputation: 727Reputation: 727Reputation: 727
It should work but I've never had the need to configure multiple subnets. Just add another section.

subnet 192.168.1.0 netmask 255.255.255.0 {
range 192.168.1.50 192.168.1.200;
}

subnet 192.168.2.0 netmask 255.255.255.0 {
range 192.168.2.50 192.168.2.200;
}

See man pages for additional help.
http://seth.positivism.org/man.cgi/8/dhcpd
 
Old 05-17-2005, 09:51 AM   #3
Darin
Senior Member
 
Registered: Jan 2003
Location: Portland, OR USA
Distribution: Slackware, SLAX, Gentoo, RH/Fedora
Posts: 1,024

Rep: Reputation: 45
The problem with that is it has no way to distinguish which hosts should belong to which network unless you specify all of the MAC addresses. If you are serving DHCP to multiple subnets out one interface then since DHCP requests are layer 2 and don't involve the IP address (yet, at least not the request itself) you will be randomly placing the clients on either network. This is of course assuming it is even possible to get DHCP to listen for two subnets on the same interface, which I have never had reason to try (due to the issue stated above) so do not know if it's possible.
 
Old 05-17-2005, 10:34 AM   #4
fr_laz
Member
 
Registered: Jan 2005
Location: Cork Ireland
Distribution: Debian
Posts: 384

Rep: Reputation: 32
Hi,

It seems to me that this could be interesting in 2 configurations :
1/ When using vlans... the dhcp requests would be in the one vlan or the other... so that should work.
2/ When forwarding dhcp request over a layer 3 network : I know that Cisco routers can forward packets from a subnet to another. They add the IP of their interface - which first received the dhcp request - in the request so that the dhcp server knows what IP to give. I've seen it, but I had not access to the dhcp server's config, so I don't know how this could work with Linux box (how to set up the Linux router ? How to set up the Linux dhcp server ?)

I wonder about these last 2 questions for a long time... I'll create another thread for these.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Linux DHCP-server + Cisco uBR7246. dr_sad Linux - Software 14 08-17-2005 10:34 PM
Linux DNS / DHCP server helppp shane200_ Linux - Networking 2 07-04-2005 10:14 PM
DHCP Server doesn't answer on Suse Linux 9.2 mikfig Linux - Networking 9 12-23-2004 12:22 AM
Linux machine as DHCP server spony Linux - Networking 4 12-23-2003 08:47 AM
Redhat Linux server not getting ip comcast dhcp server munisp Linux - Networking 1 03-24-2003 12:26 PM


All times are GMT -5. The time now is 04:59 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration