Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
ffb2d9a4
Commit
ffb2d9a4
authored
Mar 27, 2003
by
Robert Ricci
Browse files
Update the dhcpd.conf.template for isc-dhcpd3.
Allow use of node classes, as well as types, in the template file.
parent
a495bcfb
Changes
2
Hide whitespace changes
Inline
Side-by-side
db/dhcpd_makeconf.in
View file @
ffb2d9a4
...
...
@@ -62,7 +62,8 @@ while (<IF>) {
if
(
$opt
{
v
})
{
$query
.=
"
LEFT JOIN reserved AS r ON n.node_id = r.node_id
";
}
$query
.=
"
WHERE n.type='
$nodetype
' AND i.card = t.control_net
";
$query
.=
"
WHERE (n.type='
$nodetype
' OR t.class='
$nodetype
')
";
$query
.=
"
AND i.card = t.control_net
";
$query
.=
"
ORDER BY n.priority
";
my
$result
=
DBQueryFatal
(
$query
);
...
...
dhcpd/dhcpd.conf.template
View file @
ffb2d9a4
...
...
@@ -20,12 +20,39 @@ option root-path "/tftpboot";
default-lease-time 36000; # 10 hours
max-lease-time 36000; # 10 hours
subnet 155.101.132.0 netmask 255.255.252.0 {
option subnet-mask 255.255.252.0;
ddns-update-style none; # req'd vers 3 directive
# Define the PXE option space
# Code 1: Multicast IP address of bootfile
# Code 2: UDP port that client should monitor for MTFTP responses
# Code 3: UDP port that MTFTP servers are using to listen for MTFTP requests
# Code 4: Number of secondes a client must listen for activity before trying
# to start a new MTFTP transfer
# Code 5: Number of secondes a client must listen before trying to restart
# a MTFTP transfer
option space PXE;
option PXE.mtftp-ip code 1 = ip-address;
option PXE.mtftp-cport code 2 = unsigned integer 16;
option PXE.mtftp-sport code 3 = unsigned integer 16;
option PXE.mtftp-tmout code 4 = unsigned integer 8;
option PXE.mtftp-delay code 5 = unsigned integer 8;
option PXE.discovery-control code 6 = unsigned integer 8;
option PXE.discovery-mcast-addr code 7 = ip-address;
# Place clients in the PXE class when booting from the PXE ROM. We have to
# set at least one option.
class "PXE" {
match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
option vendor-class-identifier "PXEClient";
vendor-option-space PXE;
option PXE.mtftp-ip 0.0.0.0;
}
option routers 155.101.132.1;
subnet 155.101.132.0 netmask 255.255.252.0 {
option dhcp-class-identifier "PXEClient";
option subnet-mask 255.255.252.0;
option routers 155.101.132.1;
# Example of a dynamic range. If you uncomment the following line
# (after changing the IP addresses to suitable ones, of course)
...
...
@@ -34,14 +61,13 @@ subnet 155.101.132.0 netmask 255.255.252.0 {
# testbed PCs
group {
option dhcp-class-identifier "PXEClient";
#
# For every PC nodetype, include a line like the the one below.
# These lines will be replaced with auto-generated entries for
# nodes of that type.
# nodes of that type. You can also use the class field from the
# node_types table
#
%%nodetype=pc
600
%%nodetype=pc
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment