68 CHAPTER 4: NETWORK PROTOCOL OPERATION
Troubleshooting an IP Address Configuration
Subnet and Mask IP protocol allocates one IP address for each network interface. Multiple IP
addresses can only be allocated to a device which has multiple network interfaces.
IP addresses on a device with multiple interfaces have no relationship among
themselves.
With the rapid development of the Internet, IP addresses are depleting very fast.
The traditional IP address allocation method uses up IP addresses with little
efficiency. The concept of mask and subnet was proposed to make full use of the
available IP addresses.
A mask is a 32-bit number corresponding to an IP address. The number consists of
1s and 0s. Principally, these 1s and 0s can be combined randomly. However, the
first consecutive bits are set to 1s when designing the mask. The mask is divided
into two parts, the subnet address and host address. The 1 bits and the mask
indicate the subnet address, and the other bits indicate the host address.
If there is no subnet division, then the sub-net mask is the default value and the
length of “1” indicates the net-id length. Therefore, for IP addresses of classes A,
B and C, the default values of the corresponding sub-net mask is 255.0.0.0 for
Class A, 255.255.0.0 for Class B, and 255.255.255.0 for Class C.
The mask can be used to divide a Class A network containing more than
16,000,000 hosts or a Class B network containing more than 60,000 hosts into
multiple small networks. Each small network is called a subnet. For example, for
the Class A network address 10.110.0.0, the mask 255.255.224.0 can be used to
divide the network into 8 subnets: (10.110.0.0, 10.110.32.0, 10.110.64.0, and so
on). Each subnet can contain more than 8000 hosts.
Configuring an IP
Address
The following sections describe the tasks for configuring an IP address:
Configure IP Address and HostName for a Host
Configuring the IP Address of the VLAN Interface
Displaying and Debugging an IP Address
Configure IP Address and HostName for a Host
Perform the following configuration in System view.
By default, there is no host name associated to any host IP address.
Configuring the IP Address of the VLAN Interface
You can configure an IP address for every VLAN interface of the Ethernet Switch.
Tabl e 62 Configure the Host Name and the Corresponding IP Address
Operation Command
Configure the host name and the
corresponding IP address
ip host hostname ip-address
Delete the host name and the corresponding
IP address
undo ip host hostname [
ip-address ]