Press "Enter" to skip to content

IP Addressing Tutorial – Network Address, Mask (Interactive, Visual Animation 3)

adminwho 0

Q1. What is network address?
Answer: We can view network and host addresses in two ways:
1) Network-ID and Host-ID

An IP address is made of two parts, the left part is network ID, the right part is host ID.

For example, in, if 100 is a network ID, then 3.4.5 is a host ID. If 100.3 is network ID, then 4.5 is a host ID.

2) Network-address and host-address. Let's look at two examples:

IP-address Network-ID Host-ID Network-address Host-address Mask 100 4.5.6 / 8 150.1 2.3 / 16
Note: Network mask is presented as / m where m is a 2-digit decimal number between 8 ~ 31.
Note: IP, network, and host addresses are usually presented with masks.

Q2. What is mask?
Answer. IP uses network mask to break up a 32-bit IP-address into network-ID and host-ID. Network-address is made of network-ID bits on the left and 0 bits on the right.

For example, for, 16 is the network mask, 150.1 is network-ID, is network-address, 2.3 is host-ID, is host-address. Network-address is used by routers to forward packets. Host address is used to distinguish hosts in the same network.

Q3. Why network addresses?
Answer: When numbers are too many, we use hierarchical structure to manage them. For example, telephone number are structured as.

For example, 086.021.1234.5678 is a number in China, Shanghais. The voice message is switched by country code, city code, and prefix. Structured phone numbers are much easier to switch than flat 10-digit phone numbers.

Internet faces a similar situation. There are nearly 4.2 billion addresses (IP has 32 bits. Or 2 ^ 32 individual addresses.) Routers use routing tables to foreword packets. Obviously, it's much easier for router to handle structured addresses than 4 billion flat ones.

IP's solution is to use network-addresses to forward packets, not individual ones. Network mask breaks an address into a network-ID and a host-ID. Routing tables use network addresses, not IP addresses.

For example,
– network has 16,777,216 addresses. In a routing table, (, next hop interface) says: forward packets with the same destination network to the same next hop interface.
– network has 65,536 addresses. In a routing table, (, next hop interface) takes care of forwarding 65,536 individual addresses in network.
– network has 65,536 IP addresses. In a routing table, (, next hop interface) takes care of forwarding 65,536 individual address in network.
– has 256 IP addresses. In a routing table, (, next hop interface) forwards 256 IP addresses in network to the next hop interface.

Q4. How present mask in decimal?
Answer. Present mask the same way as IP address. For example.
/ 8 is presented as
/ 16 is presented as
/ 24 is presented as

Q5. Why mask length is multiple of 8 but?
Answer: There are two type of IP addressing schemes: classful and classless. What we've talked so far is classful. Classless IP address can use mask of any length. See next tutorials for details.

This article is the FAQ of an interactive animation. You can play this animation listed under External links.

Source by Ishun Chang

Leave a Reply

Your email address will not be published. Required fields are marked *