LinuxQuestions.org
Visit the LQ Articles and Editorials section
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-12-2003, 03:27 AM   #1
Robert0380
Guru
 
Registered: Apr 2002
Location: Atlanta
Distribution: Gentoo
Posts: 1,280

Rep: Reputation: 47
dchpd, multiple interfaces


For now this is all hypothetical:

I have a Linux router with 4 NICs

eth0 - 192.168.1.100, is connected to another router

eth1: 10.0.1.1 - network 1 netmask 255.255.255.0
eth2: 10.0.2.1 - network 2 netmask 255.255.255.0
eth3: 10.0.3.1 - network 3 netmask 255.255.255.0

is it possible to run dhcpd on this router and have it give out ip addresses on the eths 1-3 based on the network...i.e is it possible to set up dhcp to give out adresses 10.0.1.2-10.0.1.254 on eth1, 10.0.2.2-10.0.2.254 on eth 2 and 10.0.3.2-10.0.3.254 on eth3? I already know about forwarding and getting the networks communicating, but can 1 Linux box handle 3 different networks pertaining to dhcp leases. Right now I have it setup to give out all its IP addresses on eth1. 10.0.1.2-10.0.254.254


Thanks
 
Old 05-12-2003, 01:36 PM   #2
Robert0380
Guru
 
Registered: Apr 2002
Location: Atlanta
Distribution: Gentoo
Posts: 1,280

Original Poster
Rep: Reputation: 47
well, i know it wont allow mulitple instances of dhcpd
 
Old 05-12-2003, 02:43 PM   #3
dorian33
Member
 
Registered: Jan 2003
Location: Poland, Warsaw
Distribution: LFS, Gentoo
Posts: 587

Rep: Reputation: 32
Of course, you can. The dhcpd.conf can contain (for instance):
Code:
subnet 10.0.1.1 netmask 255.255.255.0 {
  option routers                      router_ip.;
  option subnet-mask              255.255.255.0;
  ..........
  range dynamic-bootp 10.0.1.2   10.0.1.254;
  default-lease-time 21600;
  max-lease-time 43200;
}
subnet 10.0.2.1 netmask 255.255.255.0 {
  option routers                      router_ip.;
  option subnet-mask              255.255.255.0;
  ..........
  range dynamic-bootp 10.0.2.2   10.0.2.254;
  default-lease-time 21600;
  max-lease-time 43200;
}
etc.....
 
Old 05-13-2003, 09:19 AM   #4
Robert0380
Guru
 
Registered: Apr 2002
Location: Atlanta
Distribution: Gentoo
Posts: 1,280

Original Poster
Rep: Reputation: 47
so if i have 2 NICs, with IPs 10.0.1.1 and 10.0.2.1, and i run dhcpcd, will it automatically listen on those 2 interfaces?
 
Old 05-13-2003, 12:57 PM   #5
dorian33
Member
 
Registered: Jan 2003
Location: Poland, Warsaw
Distribution: LFS, Gentoo
Posts: 587

Rep: Reputation: 32
Quote:
Originally posted by Robert0380
so if i have 2 NICs, with IPs 10.0.1.1 and 10.0.2.1, and i run dhcpcd, will it automatically listen on those 2 interfaces?
According to the manual - yes. What is more there is no way to set any interface not be serving dhcp.
 
  


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
Red Hat 7.3 and multiple gateways on multiple interfaces bluefmc Linux - Networking 2 11-19-2004 06:01 PM
Multiple Ethernet Interfaces gjs286 Linux - Networking 1 04-19-2004 02:09 PM
multiple loopback interfaces arkin Linux - Networking 1 11-18-2003 05:22 PM
DHCPd for multiple interfaces Noerr Linux - Networking 2 02-07-2003 07:40 PM
Multiple interfaces prroblem liuyangtj Linux - Networking 9 09-25-2001 04:20 AM


All times are GMT -5. The time now is 02:32 AM.

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