Configuring IP Address 69
Perform the following configuration in VLAN interface view.
The network ID of an IP address is identified by the mask. For example, the IP
address of a VLAN interface is 129.9.30.42 and the mask is 255.255.0.0. After
performing the AND operation for the IP address and the mask, you can assign
that device to the network segment 129.9.0.0.
Generally, it is sufficient to configure one IP address for an interface. However, you
can also configure more than one IP address for an interface so that it can be
connected to several subnets. Among these IP addresses, one is the primary IP
address and all others are secondary.
By default, the IP address of a VLAN interface is null.
Displaying and Debugging an IP Address
Use the display command in all views to display the IP address configuration on
interfaces, and to verify configuration.
Example: Configuring an IP Address
Configure the IP address as 129.2.2.1 and subnet mask as 255.255.255.0 for the
VLAN interface 1 of the Ethernet Switch.
Table 63 Configure IP Address for a VLAN Interface
Operation Command
Configure IP address for a VLAN interface ip address ip-address net-mask [
sub ]
Delete the IP address of a VLAN interface [ undo ] ip address [ ip-address {
net-mask | mask-length } [ sub ] ]
Table 64 Display and Debug IP Address
Operation Command
Display all hosts on the network and the
corresponding IP addresses
display ip hosts
Display the configurations of each interface display ip interface vlan-interface vlan-id