Phuong phap chia subnet nhanh nhat
- 1. PH??NG PH?P T?NH SUBNET NHANH NH?T
? M?t ??a ch? IP v.4 c¨® 32 bit, t¨¢ch th¨¤nh 2 ph?n: Network ID v¨¤ Host ID
- Network ID: d?y bit d¨´ng ¡°??nh danh¡± cho m?ng IP (nh? ??a ch? c?a 1 con h?m / ng?).
- Host ID: d?y bit d¨´ng ¡°??nh danh¡± cho 1 host trong m?ng ?¨® (nh? s? nh¨¤ trong h?m)
? Trong m?t Network c¨® n ??a ch? IP (t? 0 ??n n-1):
- ??a ch? IP ??u ti¨ºn ???c d¨´ng l¨¤m ¡°??nh danh¡± cho m?ng ?¨®.
- ??a ch? IP cu?i c¨´ng ???c d¨´ng l¨¤m ??a ch? broadcast cho to¨¤n m?ng ?¨®.
? Nh? v?y: M?t m?ng c¨® n ??a ch? IP th¨¬ ch? c¨® n-2 ??a ch? IP ???c d¨´ng g¨¢n cho hosts
B?ng tra subnet ???c chia ra t? m?ng class C:
STT
S? bit
Net.ID
Subnet Mask S? l??ng m?ng
S? l??ng ??a ch?
IP trong m?ng
0 Class C 24 255.255.255.0 20
= 1 m?ng 256
1 Class C + 1 25 255.255.255.128 21
= 2 m?ng 128
2 Class C + 2 26 255.255.255.192 22
= 4 m?ng 64
3 Class C + 3 27 255.255.255.224 23
= 8 m?ng 32
4 Class C + 4 28 255.255.255.240 24
= 16 m?ng 16
5 Class C + 5 29 255.255.255.248 25
= 32 m?ng 8
6 Class C + 6 30 255.255.255.252 26
= 64 m?ng 4
7 Class C + 7 31 255.255.255.254 27
= 128 m?ng 2
C¨¢c v¨ª d?:
T¨¬nh hu?ng 1:
C?ng ty ABC s? d?ng m?t ???ng m?ng 192.168.4.0 v¨¤ s? d?ng subnet mask 255.255.255.224
?? chia subnet. S? l??ng host t?i ?a c¨® th? s? d?ng c?a m?i subnet l¨¤ ?
Gi?i ?¨¢p:
- ?ng v?i Subnet Mask255.255.255.224,=> tra v¨¤o d¨°ng th? 3 => m?i Subnet c¨® 32 ??a ch?
- V?y: S? l??ng ??a ch? t?i ?a c¨® th? s? d?ng c?a m?i subnet l¨¤: 32 ¨C 2 = 30 ??a ch?.
T¨¬nh hu?ng 2:
X¨¢c ??nh ??a ch? ???ng m?ng (Network ID address) v¨¤ ??a ch? Broadcast (Network Broadcast
Address) c?a ???ng m?ng ?¨®, khi bi?t ??a ch? IP l¨¤ 198.101.6.85/26
Gi?i ?¨¢p:
- ??a ch? IP l¨¤ 198.101.6.85/26,=> tra v¨¤o d¨°ng th? 2 => m?i Subnet c¨® 64 ??a ch?
- D?y IP addrs c?a
o Subnet 1: t? 0 ? 63
o Subnet 2: t? 64 ? 127
- 2. o Subnet 3: t? 128? 191
o Subnet 4: t? 192 ? 255
- IP address ?? cho (198.101.6.85/26) thu?c Subnet 2
- V?y:
o Network ID address: 192.168.6.64 /26
o Network Broadcast Address: 192.168.6.127 /26
T¨¬nh hu?ng 3:
192.168.30.105 /27 ?
Gi?i ?¨¢p:
- ??a ch? IP l¨¤ 192.168.30.105 /27,=> tra v¨¤o d¨°ng th? 3 ta th?y: Class C ???c chia th¨¤nh 8
Subnet (m?ng con), m?i Subnet c¨® 32 ??a ch?
- D?y IP addrs c?a:
o Subnet 1: t? 0 ?31
o Subnet 2: t? 32?63
o Subnet 3: t? 64?95
o Subnet 4: t? 96?127
o Subnet 5: t? 128?159
o Subnet 6: t? 160?191
o Subnet 7: t? 192?223
o Subnet 8: t? 224 ? 255
- IP address ?? cho (192.168.30.135 /27) thu?c Subnet 5 (t? 192.168.30.128 /27??n
192.168.30.159 /27)