[ale] dhcpd to multiple vlans from one server
Michael Still
stillwaxin at gmail.com
Fri Jan 23 10:29:04 EST 2015
You don't need to do anything fancy here. This functionality is built into
isc-dhcpd. Just tell your routers in each subnet to relay dhcp to your dhcp
server ip and put this kinda stuff in your config:
group foo {
option domain-name "mydomain.name";
option domain-name-servers myrecursivednsserver1, myrecursivednsserver2;
option ntp-servers myntpserver1, myntpserver2;
default-lease-time 3600;
max-lease-time 3600;
shared-network network1 { <--- VLANX
subnet 172.16.0.0 netmask 255.255.255.192 {
range 172.16.0.10 172.16.0.20;
option routers 172..16.0.1;
option subnet-mask 255.255.255.192;
}
}
shared-network network2 { <--- VLANY
subnet 192.168.0.0 netmask 255.255.255.192 {
range 192.168.0.10 192.168.0.20;
option option-150 myvoipboxip;
option routers 192.168.0.1;
option subnet-mask 255.255.255.192;
}
}
Every router will source a *new* packet using the interface IP from the
subnet it *received* the dhcp request on so the dhcp server knows which
pool to use to issue IPs to the clients. I ran a global network with 2x
dhcp servers this way.
On Thu, Jan 22, 2015 at 11:57 PM, Robert L. Harris <
robert.l.harris at gmail.com> wrote:
> That looks like what I'm looking for.
>
>
> On Thu Jan 22 2015 at 9:26:43 PM James Sumners <james.sumners at gmail.com>
> wrote:
>
>> It's something you would take care of at the switch level if you don't
>> want to have an interface per vlan on your DHCP server --
>> https://lists.isc.org/pipermail/dhcp-users/2006-August/001509.html
>>
>> On Thu, Jan 22, 2015 at 7:37 PM, Robert L. Harris <
>> robert.l.harris at gmail.com> wrote:
>>
>>> Ok, so if I have 2 subnets:
>>>
>>> 172.20.1/24 on vlan 21
>>> 172.20.2/24 on vlan 22
>>>
>>> If a host plugs into a port assigned to vlan 22, how do I make sure
>>> dhcpd gives out the right address? That's the part of the designation I'm
>>> missing.
>>>
>>> Robert
>>>
>>>
>>> On Thu Jan 22 2015 at 5:17:25 PM James Sumners <james.sumners at gmail.com>
>>> wrote:
>>>
>>>> You just have to define the subnets in the config and put each subnet's
>>>> pool within its respective block. No need for aliased IPs.
>>>>
>>>> On Thursday, January 22, 2015, Robert L. Harris <
>>>> robert.l.harris at gmail.com> wrote:
>>>>
>>>>>
>>>>> Anyone have a dhcpd serving multiple subnets to multiple vlans from a
>>>>> single server on a trunk they can share configs? I don't want to spawn a
>>>>> bunch of servers and if I can do it with a single interface that would be
>>>>> ideal. If I have to go with eth0.0, eth0.1, etc that's a good second
>>>>> choice.
>>>>>
>>>>> Robert
>>>>>
>>>>>
>>>>
>>>> --
>>>> James Sumners
>>>> http://james.sumners.info/ (technical profile)
>>>> http://jrfom.com/ (personal site)
>>>> http://haplo.bandcamp.com/ (band page)
>>>>
>>>> _______________________________________________
>>>> Ale mailing list
>>>> Ale at ale.org
>>>> http://mail.ale.org/mailman/listinfo/ale
>>>> See JOBS, ANNOUNCE and SCHOOLS lists at
>>>> http://mail.ale.org/mailman/listinfo
>>>>
>>>
>>> _______________________________________________
>>> Ale mailing list
>>> Ale at ale.org
>>> http://mail.ale.org/mailman/listinfo/ale
>>> See JOBS, ANNOUNCE and SCHOOLS lists at
>>> http://mail.ale.org/mailman/listinfo
>>>
>>>
>>
>>
>> --
>> James Sumners
>> http://james.sumners.info/ (technical profile)
>> http://jrfom.com/ (personal site)
>> http://haplo.bandcamp.com/ (band page)
>> _______________________________________________
>> Ale mailing list
>> Ale at ale.org
>> http://mail.ale.org/mailman/listinfo/ale
>> See JOBS, ANNOUNCE and SCHOOLS lists at
>> http://mail.ale.org/mailman/listinfo
>>
>
> _______________________________________________
> Ale mailing list
> Ale at ale.org
> http://mail.ale.org/mailman/listinfo/ale
> See JOBS, ANNOUNCE and SCHOOLS lists at
> http://mail.ale.org/mailman/listinfo
>
>
--
[stillwaxin at gmail.com ~]$ cat .signature
cat: .signature: No such file or directory
[stillwaxin at gmail.com ~]$
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ale.org/pipermail/ale/attachments/20150123/b016e7d2/attachment.html>
More information about the Ale
mailing list