Assign subnet's per group
Jason Gerfen
jason.gerfen at scl.utah.edu
Thu Oct 22 16:33:52 UTC 2009
You forgot the 'next-server' param in the group config.
Hugo Ferreira wrote:
> By Jason's example, before trying others:
>
> group xpto {
> filename "xpto";
next-server 192.168.1.1;
> host xpto1 { hardware ethernet 00:c0:c3:49:2b:57; }
> host xpto2 { hardware ethernet 00:c0:c3:80:fc:32; }
> host xpto3 { hardware ethernet 00:c0:c3:22:46:81; }
> }
>
> shared-network Vlan1{
> subnet 10.1.0.0 netmask 255.255.240.0 {
> option routers 10.1.0.1;
> option subnet-mask 255.255.240.0;
> allow unknown-clients;
> }
>
>
> subnet 10.1.64.0 netmask 255.255.255.0 {
> option routers 10.1.64.253;
> option subnet-mask 255.255.255.0;
> filename "DDI";
> deny unknown-clients;
> }
> }
>
> I guess this should work. Any suggestion or notice regarding this
> configuration?
>
Test it first: dhcpd -t -cf /path/to/dhcpd.conf
>
> On Thu, Oct 22, 2009 at 5:03 PM, Jason Gerfen
> <jason.gerfen at scl.utah.edu <mailto:jason.gerfen at scl.utah.edu>> wrote:
>
> Yes. That example will work. And here are a couple of others. If
> you ever question your configuration just test the dhcpd.conf like
> this:
>
> %> dhcpd -t -cf /path/to/dhcpd.conf
>
> The examples to help you out
>
> Static hosts in a group:
> group {
> filename "pxelinux.0";
> next-server 192.168.1.2;
>
> ## Static Hosts Assigned to PXE Group ##
> host hostname1 {
> hardware ethernet 00:50:fc:c1:67:3a;
> fixed-address 192.168.1.3;
> }
> host hostname2 {
> hardware ethernet 00:16:76:b0:23:64;
> fixed-address 192.168.1.4;
> }
> }
>
> A subnet definition with a scope and bootp options:
> subnet 192.168.1.0 netmask 255.255.255.0 {
> option domain-name-servers 192.168.1.25, 192.168.1.26;
> option routers 192.168.1.1;
> range 192.168.1.2 192.168.1.24;
> filename "pxelinux.0";
> next-server 192.168.1.26;
> option ip-forwarding off;
> }
>
> A pool with bootp options:
> pool {
> option domain-name-servers 192.168.1.25, 192.168.1.26;
> range 192.168.1.3 192.168.1.24;
> filename "pxelinux.0";
> next-server "192.168.1.26";
> allow unknown-clients;
> }
>
> And the same pool assigned to a subnet:
> subnet 192.168.1.0 netmask 255.255.255.0 {
> option domain-name-servers 192.168.1.25, 192.168.1.26;
> option routers 192.168.1.1;
> option ip-forwarding off;
> pool {
> option domain-name-servers 192.168.1.25, 192.168.1.26;
> range 192.168.1.3 192.168.1.24;
> filename "pxelinux.0";
> next-server "192.168.1.26";
> allow unknown-clients;
> }
> }
>
>
> Hugo Ferreira wrote:
>
>
> Hi
>
>
> Wondering if i can do something like this:
>
>
> Group some MAC addresses, e.g., per company department, as in
> man dhcpd.conf
>
> group {
>
> filename "Xncd19r";
> next-server ncd-booter;
>
> host ncd1 { hardware ethernet 0:c0:c3:49:2b:57; }
> host ncd4 { hardware ethernet 0:c0:c3:80:fc:32; }
> host ncd8 { hardware ethernet 0:c0:c3:22:46:81; }
>
> }
>
>
> And then assign this group to a subnet.
>
> Something like
>
>
> subnet 1.1.1.1 255.255.255.0 {
> range blablabla;
> */allow group;/*
> deny unknown-clients;
> }
>
>
> Can’t find the right syntax for that allow group or allow from
> group or something like that.
>
>
> 1. Is my idea possible?
>
> 2. If so, can you help me finding the right syntax?
>
>
> Regards
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org <mailto:dhcp-users at lists.isc.org>
> https://lists.isc.org/mailman/listinfo/dhcp-users
>
>
>
> --
> Jason Gerfen
> Systems Administration/Web application development
> jason.gerfen at scl.utah.edu <mailto:jason.gerfen at scl.utah.edu>
>
> Marriott Library
> Lab Systems PC
> 295 South 1500 East
> Salt Lake City, Utah 84112-0806
> Ext 5-9810
>
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org <mailto:dhcp-users at lists.isc.org>
> https://lists.isc.org/mailman/listinfo/dhcp-users
>
>
>
>
> --
> Hugo Ferreira
> <?
> hugoferreira at gmail.com <mailto:hugoferreira at gmail.com>
> ?>
> ------------------------------------------------------------------------
>
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users
--
Jason Gerfen
Systems Administration/Web application development
jason.gerfen at scl.utah.edu
Marriott Library
Lab Systems PC
295 South 1500 East
Salt Lake City, Utah 84112-0806
Ext 5-9810
More information about the dhcp-users
mailing list