VLSM TABLE & SUBNETTING (important) - Dleifnesor/NET-150 GitHub Wiki

The subnet mask uses 1s and 0s to indicate that the corresponding bits on the ip address are reserved for the network id and the rest for the host id range.

Network prefixes The address is followed by a number that represents the number of bits beginning fom the left that apply to a network a slash (/) is used to separate the address and the prefix length


IPv4 and IPv6 Subnetting

Subnetting is the practice of dividing a network into smaller logical subnetworks (subnets). It improves routing efficiency, enhances security, and better utilizes IP address space.


IPv4 Subnetting

IPv4 addresses are 32-bit numbers, typically written in dotted-decimal notation (e.g., 192.168.1.1).

Common IPv4 Subnet Masks

CIDR Notation Subnet Mask Number of Hosts Number of Subnets
/8 255.0.0.0 16,777,214 1
/16 255.255.0.0 65,534 256
/24 255.255.255.0 254 65,536
/30 255.255.255.252 2 1,073,741,824

Additional Resources


image

IPv4 and IPv6 Subnetting

Subnetting is the practice of dividing a network into smaller logical subnetworks (subnets). It improves routing efficiency, enhances security, and better utilizes IP address space.


IPv4 Subnetting

IPv4 addresses are 32-bit numbers, typically written in dotted-decimal notation (e.g., 192.168.1.1).

Common IPv4 Subnet Masks

CIDR Notation Subnet Mask Number of Hosts Number of Subnets
/8 255.0.0.0 16,777,214 1
/16 255.255.0.0 65,534 256
/24 255.255.255.0 254 65,536
/30 255.255.255.252 2 1,073,741,824

How to Calculate IPv4 Subnets

  1. Identify Network and Host Portions: Use the subnet mask to distinguish.
  2. Determine Subnet Increment: Based on borrowed bits.
  3. Calculate Range of IP Addresses: Start from network address, increment by subnet size.

Example

  • IP Address: 192.168.10.0/24
  • Subnet Mask: 255.255.255.0
  • Subnets if divided further into /26:

{060245BA-7A75-434B-89D4-BE4F415C4B44}

Subnet Address First Host Last Host Broadcast Address
192.168.10.0/26 192.168.10.1 192.168.10.62 192.168.10.63
192.168.10.64/26 192.168.10.65 192.168.10.126 192.168.10.127

image

IPv6 Subnetting

IPv6 addresses are 128-bit numbers, written in hexadecimal colon-separated notation (e.g., 2001:0db8:85a3::8a2e:0370:7334).

Common IPv6 Prefixes

Prefix Length Typical Use Case Number of Subnets Hosts per Subnet
/48 Site (Large Organization) 65,536 ~1.2x10^24
/56 ISP allocation to a customer 256 ~4.7x10^21
/64 Standard single LAN segment 1 ~1.8x10^19

How to Calculate IPv6 Subnets

  1. Focus on the Network Portion: Often /48 or /64 boundaries.
  2. Borrow Bits to Subnet: Extend beyond default prefix (e.g., /64 to /68).
  3. Simplified Calculations: Each nibble (4 bits) aligns with a hexadecimal digit.

Example

  • IPv6 Address: 2001:db8:abcd::/48
  • Dividing into /52 subnets:
Subnet Address Notes
2001:db8:abcd:0::/52 First subnet
2001:db8:abcd:1000::/52 Second subnet
2001:db8:abcd:2000::/52 Third subnet

Key Differences between IPv4 and IPv6 Subnetting

Feature IPv4 IPv6
Address Size 32 bits 128 bits
Subnetting Purpose Maximize address efficiency Facilitate efficient routing
Address Allocation Scarce, careful assignment Abundant, easier assignment
CIDR Flexibility High Moderate (commonly /64)

Additional Resources


Tip: Practice makes perfect. Regularly work through subnetting problems to build speed and accuracy.

⚠️ **GitHub.com Fallback** ⚠️