1-3In the absence of subnetting, some special addresses such as the addresses with the net ID of all zerosand the addresses with the host ID of all ones, are not assignable to hosts. The same is true forsubnetting. When designing your network, you should note that subnetting is somewhat a tradeoffbetween subnets and accommodated hosts. For example, a Class B network can accommodate 65,534(2 16 – 2. Of the two deducted Class B addresses, one with an all-one host ID is the broadcast addressand the other with an all-zero host ID is the network address) hosts before being subnetted. After youbreak it down into 512 (29) subnets by using the first 9 bits of the host ID for the subnet, you have only 7bits for the host ID and thus have only 126 (27 – 2) hosts in each subnet. The maximum number of hostsis thus 64,512 (512 × 126), 1022 less after the network is subnetted.Class A, B, and C networks, before being subnetted, use these default masks (also called naturalmasks): 255.0.0.0, 255.255.0.0, and 255.255.255.0 respectively.Configuring IP AddressesAn interface needs an IP address to communicate with other devices. You can assign an IP address toa VLAN interface or a loopback interface on a switch. Besides directly assigning an IP address to theVLAN interface, you may configure the VLAN interface to obtain one through BOOTP, or DHCP asalternatives. If you change the way an interface obtains an IP address, from manual assignment toBOOTP for example, the IP address obtained from BOOTP will overwrite the old one manuallyassigned.This chapter only covers how to assign an IP address manually. For the other two approaches, refer toDHCP Configuration in the IP Services Volume.This section includes:z Assigning an IP Address to an Interfacez IP Addressing Configuration ExampleAssigning an IP Address to an InterfaceYou may assign an interface on the S5120-EI series switch multiple IP addresses, one primary andmultiple secondaries, to connect multiple logical subnets on the same physical subnet.Follow these steps to assign an IP address to an interface:To do… Use the command… RemarksEnter system view system-view ––Enter interface view interface interface-typeinterface-number ––Assign an IP address tothe interfaceip address ip-address { mask| mask-length } [ sub ]RequiredNo IP address is assigned by default.