Browse Source

added subnet configs

secnet 2 years ago
parent
commit
e0a4f71e3d
2 changed files with 53 additions and 86 deletions
  1. 3
    0
      Makefile
  2. 50
    86
      dhcpd.conf

+ 3
- 0
Makefile View File

@@ -0,0 +1,3 @@
1
+all:
2
+	sudo git pull --ff-only
3
+	sudo systemctl restart isc-dhcp-server

+ 50
- 86
dhcpd.conf View File

@@ -7,8 +7,8 @@
7 7
 #
8 8
 
9 9
 # option definitions common to all supported networks...
10
-option domain-name "example.org";
11
-option domain-name-servers ns1.example.org, ns2.example.org;
10
+option domain-name "cslabs.clarkson.edu";
11
+option domain-name-servers 128.153.145.3, 8.8.8.8;
12 12
 
13 13
 default-lease-time 600;
14 14
 max-lease-time 7200;
@@ -21,91 +21,55 @@ ddns-update-style none;
21 21
 
22 22
 # If this DHCP server is the official DHCP server for the local
23 23
 # network, the authoritative directive should be uncommented.
24
-#authoritative;
25
-
26
-# Use this to send dhcp log messages to a different log file (you also
27
-# have to hack syslog.conf to complete the redirection).
28
-#log-facility local7;
24
+authoritative;
29 25
 
30 26
 # No service will be given on this subnet, but declaring it helps the 
31 27
 # DHCP server to understand the network topology.
28
+subnet 128.153.144.0 netmask 255.255.255.0 {}
29
+subnet 128.153.145.0 netmask 255.255.255.0 {}
30
+
31
+# Subnet declaration for ctl.sec network
32
+
33
+subnet 10.2.0.0 netmask 255.255.255.0 {
34
+  range 10.2.0.100 10.2.0.254;
35
+  option routers 10.2.0.1;
36
+  option domain-name "ctl.sec";
37
+  option domain-name-servers 10.2.0.1;
38
+}
39
+
40
+# Subnet declaration for net1.sec network
41
+
42
+subnet 10.2.1.0 netmask 255.255.255.0 {
43
+  range 10.2.1.100 10.2.1.254;
44
+  option routers 10.2.1.1;
45
+  option domain-name "net1.sec";
46
+  option domain-name-servers 10.2.1.1;
47
+}
48
+
49
+# Subnet declaration for net2.sec network
50
+
51
+subnet 10.2.2.0 netmask 255.255.255.0 {
52
+  range 10.2.2.100 10.2.2.254;
53
+  option routers 10.2.2.1;
54
+  option domain-name "net2.sec";
55
+  option domain-name-servers 10.2.2.1;
56
+}
57
+
58
+# Subnet declaration for net3.sec network
59
+
60
+subnet 10.2.3.0 netmask 255.255.255.0 {
61
+  range 10.2.3.100 10.2.3.254;
62
+  option routers 10.2.3.1;
63
+  option domain-name "net3.sec";
64
+  option domain-name-servers 10.2.3.1;
65
+}
66
+
67
+# Subnet declaration for net4.sec network
68
+
69
+subnet 10.2.4.0 netmask 255.255.255.0 {
70
+  range 10.2.4.100 10.2.4.254;
71
+  option routers 10.2.4.1;
72
+  option domain-name "net4.sec";
73
+  option domain-name-servers 10.2.4.1;
74
+}
32 75
 
33
-#subnet 10.152.187.0 netmask 255.255.255.0 {
34
-#}
35
-
36
-# This is a very basic subnet declaration.
37
-
38
-#subnet 10.254.239.0 netmask 255.255.255.224 {
39
-#  range 10.254.239.10 10.254.239.20;
40
-#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
41
-#}
42
-
43
-# This declaration allows BOOTP clients to get dynamic addresses,
44
-# which we don't really recommend.
45
-
46
-#subnet 10.254.239.32 netmask 255.255.255.224 {
47
-#  range dynamic-bootp 10.254.239.40 10.254.239.60;
48
-#  option broadcast-address 10.254.239.31;
49
-#  option routers rtr-239-32-1.example.org;
50
-#}
51
-
52
-# A slightly different configuration for an internal subnet.
53
-#subnet 10.5.5.0 netmask 255.255.255.224 {
54
-#  range 10.5.5.26 10.5.5.30;
55
-#  option domain-name-servers ns1.internal.example.org;
56
-#  option domain-name "internal.example.org";
57
-#  option subnet-mask 255.255.255.224;
58
-#  option routers 10.5.5.1;
59
-#  option broadcast-address 10.5.5.31;
60
-#  default-lease-time 600;
61
-#  max-lease-time 7200;
62
-#}
63
-
64
-# Hosts which require special configuration options can be listed in
65
-# host statements.   If no address is specified, the address will be
66
-# allocated dynamically (if possible), but the host-specific information
67
-# will still come from the host declaration.
68
-
69
-#host passacaglia {
70
-#  hardware ethernet 0:0:c0:5d:bd:95;
71
-#  filename "vmunix.passacaglia";
72
-#  server-name "toccata.example.com";
73
-#}
74
-
75
-# Fixed IP addresses can also be specified for hosts.   These addresses
76
-# should not also be listed as being available for dynamic assignment.
77
-# Hosts for which fixed IP addresses have been specified can boot using
78
-# BOOTP or DHCP.   Hosts for which no fixed address is specified can only
79
-# be booted with DHCP, unless there is an address range on the subnet
80
-# to which a BOOTP client is connected which has the dynamic-bootp flag
81
-# set.
82
-#host fantasia {
83
-#  hardware ethernet 08:00:07:26:c0:a5;
84
-#  fixed-address fantasia.example.com;
85
-#}
86
-
87
-# You can declare a class of clients and then do address allocation
88
-# based on that.   The example below shows a case where all clients
89
-# in a certain class get addresses on the 10.17.224/24 subnet, and all
90
-# other clients get addresses on the 10.0.29/24 subnet.
91
-
92
-#class "foo" {
93
-#  match if substring (option vendor-class-identifier, 0, 4) = "SUNW";
94
-#}
95
-
96
-#shared-network 224-29 {
97
-#  subnet 10.17.224.0 netmask 255.255.255.0 {
98
-#    option routers rtr-224.example.org;
99
-#  }
100
-#  subnet 10.0.29.0 netmask 255.255.255.0 {
101
-#    option routers rtr-29.example.org;
102
-#  }
103
-#  pool {
104
-#    allow members of "foo";
105
-#    range 10.17.224.10 10.17.224.250;
106
-#  }
107
-#  pool {
108
-#    deny members of "foo";
109
-#    range 10.0.29.10 10.0.29.230;
110
-#  }
111
-#}

Loading…
Cancel
Save