Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Anyone here knows how to setup a linux dhcp server with multiple scopes? I have 3 different subnets in our network. 192.168.1.x, 192.168.2.x and 192.168.3.x. All my servers are in .1 subnets and one of them is a dhcp. Now, I want also that my .2 and .3 subnets will taken care of an one dhcp server which part of .1 subnet. I'm using a linux router to communicate with different subnets.
It depends on your setup. Are the subnets physically separate? If so, you'd need to connect different nic cards to the different switches. If there are in the same physical network, then all you have to do is modify dhcpd.conf.
Then you would need to install a separate nic for each subnet and statically assign them the address 192.168.x.1 for the respective network. Then you would define the subnets in dhcpd.conf.
If anyone has a more elegant solution, feel free to jump in, but that's the only way that I know.
Or a single NIC is fine if the router supports a feature like ip-helper address (cisco) basically you are telling the router to relay DHCP requests to a SPECIFIC IP address that is the location of the DHCP server.
I had dual DHCP servers setup to handle 24 different subnets using this method. no problems.
Note there is a dhcp-relay package available for Linux as well if you are using Linux machines as routers.
If you are hosting multiple subnets in a large network you might also want to look at configuring DHCP fail-over in your DHCP servers, and then setup 2 machines as DHCP servers.
that's a real ugly way to do it, but it depends what the rest of the network does as to wether the best solutions are feasible. you *should* place a DHCP relay agent on each subnet, any server or pc can actually perform this function, but normally it's the router or firewall. this just accepts dhcp requests and directly forwards to an existing DHCP server like this one.
as for doing it without, you can use 802.1q trunking on a single nic to get the same result.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.