-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path00IPv4_Subnetting.txt
224 lines (191 loc) · 8.99 KB
/
00IPv4_Subnetting.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
# VLSM - Variable Length Subnet Mask
// Binary to Decimal Conversion Table:
======================================
(2^7) (2^6) (2^5) (2^4) (2^3) (2^2) (2^1) (2^0)
128 64 32 16 8 4 2 1
1 0 1 0 1 1 0 0 ---> 172
1 0 0 1 0 0 0 0 ---> 16
0 0 0 0 0 1 0 1 ---> 5
0 0 0 0 1 0 1 0 ---> 10
1 1 0 0 0 0 0 0 ---> 192
1 0 1 0 1 0 0 0 ---> 168
1 0 0 0 0 0 0 0 ---> 128
✅ Given Network: 10.128.192.0/18
Required Host:
Admin --> 10 ---> (2^4) = 32 - 4 = 28 (New Network Address)
Marketing --> 150 ---> (2^8) = 32 - 7 = 24 (New Network Address)
HR --> 35 ---> (2^6) = 32 - 6 = 26 (New Network Address)
Accounting --> 56 ---> (2^6) = 32 - 6 = 26 (New Network Address)
Step-1: Subnet the given subnet for the host requirement of Marketing Department and assign the sixth subnet to the Marketing Department.
Step-2: From Step-1 subnet the third subnet for Accounting Department. Assign the second & third subnet to the Accounting and HR department respectively.
Step-3: Now from the Step-2 subnet the fourth subnet for the host requirement of Admin Department and assign the third subnet for Admin Department.
Solution:
=========
Step:1
======
/18 /24
10.128. 1 1 | 0 0 0 0 0 0 . | 0 0 0 0 0 0 0 0
10.128. 1 1 | 0 0 0 0 0 1 . | 0 0 0 0 0 0 0 0
10.128. 1 1 | 0 0 0 0 1 0 . | 0 0 0 0 0 0 0 0
10.128. 1 1 | 0 0 0 0 1 1 . | 0 0 0 0 0 0 0 0
10.128. 1 1 | 0 0 0 1 0 0 . | 0 0 0 0 0 0 0 0
10.128. 1 1 | 0 0 0 1 0 1 . | 0 0 0 0 0 0 0 0 ---> Sixth Subnet(Marketing Department)
Step:2
======
/24 /26
10.128. 1 1 0 0 0 0 1 0 . | 0 0 | 0 0 0 0 0 0
10.128. 1 1 0 0 0 0 1 0 . | 0 1 | 0 0 0 0 0 0 ---> Second Subnet(Accounting Department)
10.128. 1 1 0 0 0 0 1 0 . | 1 0 | 0 0 0 0 0 0 ---> Third Subnet(HR Department)
10.128. 1 1 0 0 0 0 1 0 . | 1 1 | 0 0 0 0 0 0
Step:3
======
/26 /28
10.128. 1 1 0 0 0 0 1 0 . 1 1 | 0 0 | 0 0 0 0
10.128. 1 1 0 0 0 0 1 0 . 1 1 | 0 1 | 0 0 0 0
10.128. 1 1 0 0 0 0 1 0 . 1 1 | 1 0 | 0 0 0 0 ---> Third Subnet(Admin Department)
10.128. 1 1 0 0 0 0 1 0 . 1 1 | 1 1 | 0 0 0 0
Finally we have,
Admin: 10.128.194.224/28
Marketing: 10.128.197.0/24
HR: 10.128.194.128/26
Accounting: 10.128.194.64/26
Admin Department
----------------
Network ID: 10.128.194.224/28
In Binary: 00001010.10000000.11000010.11100000
Subnet Mask: 11111111.11111111.11111111.11110000 ---> 255.255.255.240
Broadcast ID: 00001010.10000000.11000010.11111111 ---> 10.128.194.255
First Usable IP: 00001010.10000000.11000010.11100001 ---> 10.128.194.225
Last Usable IP: 00001010.10000000.11000010.11111110 ---> 10.128.194.254
Marketing Department
--------------------
Network ID: 10.128.197.0/24
In Binary: 00001010.10000000.11000101.00000000
Subnet Mask: 11111111.11111111.11111111.00000000 ---> 255.255.255.0
Broadcast ID: 00001010.10000000.11000101.11111111 ---> 10.128.197.255
First Usable IP: 00001010.10000000.11000101.00000001 ---> 10.128.197.1
Last Usable IP: 00001010.10000000.11000101.11111110 ---> 10.128.197.254
HR Department
-------------
Network ID: 10.128.194.128/26
In Binary: 00001010.10000000.11000010.10000000
Subnet Mask: 11111111.11111111.11111111.11000000 ---> 255.255.255.192
Broadcast ID: 00001010.10000000.11000010.11111111 ---> 10.128.194.255
First Usable IP: 00001010.10000000.11000010.10000001 ---> 10.128.194.129
Last Usable IP: 00001010.10000000.11000010.11111110 ---> 10.128.194.254
Accounting Department
---------------------
Network ID: 10.128.194.64/26
In Binary: 00001010.10000000.11000010.01000000
Subnet Mask: 11111111.11111111.11111111.11000000 ---> 255.255.255.192
Broadcast ID: 00001010.10000000.11000010.01111111 ---> 10.128.194.127
First Usable IP: 00001010.10000000.11000010.01000001 ---> 10.128.194.65
Last Usable IP: 00001010.10000000.11000010.01111110 ---> 10.128.194.126
✅ Given Network: 172.16.0.0/10
ABC Company: Sales - 80
Marketing - 110
HR - 10
IT - 8
Customer Service - 22
Step-1: Subnet the given subnet and assign the first subnet to Sales department and 5th subnet to the Marketing department while wasting the fewest addresses.
Step-2: From the available subnets that you have created in the Step-1, subnet further the second subnet as per the host requirement of Customer Service Department.
Step-3: From the subnets that you created in Step-2 assign the first subnet to Customer service department and subnet further the third subnet and assign the first and second subnet to HR and IT department.
Solution:
=========
(2^7) (2^6) (2^5) (2^4) (2^3) (2^2) (2^1) (2^0)
128 64 32 16 8 4 2 1
Sales Department
----------------
No. of hosts = 80
Host bits needed = 2^7
New Network address = 172.16.0.0/25 --> 2^7 = (32-7) = 25
Marketing Department
--------------------
No. of hosts = 110
Host bits needed = 2^7
New Network address = 172.16.0.0/25 --> 2^7 = (32-7) = 25
HR Department
-------------
No. of hosts = 10
Host bits needed = 2^4
New Network address = 172.16.0.0/28 --> 2^4 = (32-4) = 28
IT Department
-------------
No. of hosts = 8
Host bits needed = 2^4
New Network address = 172.16.0.0/28 --> 2^4 = (32-4) = 28
Customer Service Department
---------------------------
No. of hosts = 22
Host bits needed = 2^5
New Network address = 172.16.0.0/27 --> 2^5 = (32-5) = 27
Step-1
======
/10 /25
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 0 0.0 | 0 0 0 0 0 0 0 ----> First Subnet(Sales Department)
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 0 0.1 | 0 0 0 0 0 0 0
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 0 1.0 | 0 0 0 0 0 0 0
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 0 1.1 | 0 0 0 0 0 0 0
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 1 0.0 | 0 0 0 0 0 0 0 ----> Fifth Subnet(Marketing Department)
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 1 0.1 | 0 0 0 0 0 0 0
172.0 0 | 0 1 0 0 0 0.0 0 0 0 0 0 1 1.0 | 0 0 0 0 0 0 0
Step-2
======
/25 /27
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 | 0 0 | 0 0 0 0 0
Step-3
======
/25 /27
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 | 0 0 | 0 0 0 0 0 ----> First Subnet(Customer Service Department)
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 | 0 1 | 0 0 0 0 0
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 | 1 0 | 0 0 0 0 0
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 | 1 1 | 0 0 0 0 0
/27 /28
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 1 0 | 0 | 0 0 0 0 ----> First Subnet(HR Department)
172.0 0 0 1 0 0 0 0.0 0 0 0 0 0 0 0. 1 1 0 | 1 | 0 0 0 0 ----> Second Subnet(IT Department)
Finally we have,
Sales Department: 172.16.0.0/25
Marketing Department: 172.16.2.0/25
Customer Service Department: 172.16.0.128/27
HR Department: 172.16.0.192/28
IT Department: 172.16.0.208/28
Sales Department
----------------
Network ID: 172.16.0.0/25
In Binary: 10101100.00010000.00000000.00000000
Subnet Mask: 11111111.11111111.11111111.10000000 --> 255.255.255.128
Broadcast ID: 10101100.00010000.00000000.01111111 --> 172.16.0.127
First Usable IP: 10101100.00010000.00000000.00000001 --> 172.16.0.1
Last Usable IP : 10101100.00010000.00000000.01111110 --> 172.16.0.126
Marketing Department
--------------------
Network ID: 172.16.2.0/25
In Binary: 10101100.00010000.00000010.00000000
Subnet Mask: 11111111.11111111.11111111.10000000 ---> 255.255.255.128
Broadcast ID: 10101100.00010000.00000010.01111111 ---> 172.16.2.127
First Usable IP: 10101100.00010000.00000010.00000001 ---> 172.16.2.1
Last Usable IP: 10101100.00010000.00000010.01111110 ---> 172.16.2.126
Customer Service Department
---------------------------
Network ID: 172.16.0.128/27
In Binary: 10101100.00010000.00000000.10000000
Subnet Mask: 11111111.11111111.11111111.11100000 ---> 255.255.255.224
Broadcast ID: 10101100.00010000.00000000.10011111 ---> 172.16.0.159
First Usable IP: 10101100.00010000.00000000.10000001 ---> 172.16.0.129
Last Usable IP: 10101100.00010000.00000000.10011110 ---> 172.16.0.158
HR Department
-------------
Network ID: 172.16.0.192/28
In Binary: 10101100.00010000.00000000.11000000
Subnet Mask: 11111111.11111111.11111111.11110000 ---> 255.255.255.240
Broadcast ID: 10101100.00010000.000000000.1100111 ---> 172.16.0.199
First Usable IP: 10101100.00010000.00000000.11000001 ---> 172.16.0.193
Last Usable IP: 10101100.00010000.000000000.1100110 ---> 172.16.0.198
IT Department
-------------
Network ID: 172.16.208/28
In Binary: 10101100.00010000.00000000.11010000
Subnet Mask: 11111111.11111111.11111111.11110000 ---> 255.255.255.240
Broadcast ID: 10101100.00010000.00000000.11011111 ---> 172.16.0.223
First Usable IP: 10101100.00010000.00000000.11010001 ---> 172.16.209
Last Usable IP: 10101100.00010000.00000000.11011110 ---> 172.16.0.222