Class matching
Luka
dhcp at ml.evriala.net
Wed Oct 6 07:17:12 UTC 2010
On Wed, 2010-10-06 at 09:13 +0200, Luka wrote:
> On Sun, 2010-10-03 at 23:20 +1100, Glenn Satchell wrote:
> > Hmm, what about using groups, something like this?
>
> Yes, groups work. I've removed tftp option from class and since both
> classes are now identical, combined them into one. Moved subnet
> declarations in different files and grouped the relevant ones together:
>
> class "ab" {
> match if (substring(hardware,1,3) = 00:01:02);
> }
>
> group {
> if (option vendor-class ~~ "linksys spa.*") {
> option tftp-server-name = "10.0.0.1";
> }
> include "subnet.a";
> }
>
> group {
> if (option vendor-class = "some-vendor") {
> option tftp-server-name = "10.0.0.2";
> }
> include "subnet.b";
> }
>
> Thank you all for your help.
>
Meh, both vendor class declarations should be:
if (option vendor-class-identifier ~~ "linksys spa.*") {
option tftp-server-name = "10.0.0.x";
}
More information about the dhcp-users
mailing list