set l3-interface routed-interface address
To configure an IPv4 or IPv6 address for an L3 interface, use the set l3-interface routed-interface address command in L2/L3 configuration mode. To remove an L3 interface, use the delete form of the command.
Command Syntax
set l3-interface routed-interface <interface-name> address <address> prefix-length <number>
delete l3-interface routed-interface <interface-name>
Parameters
Parameter | Description |
routed-interface <interface-name> | Specifies a routed interface name or sub-interface name. The value is a string. |
address | IPv4 or IPv6 address. |
number | The network prefix length. The range is 4-32 for IPv4 addresses, and 1-128 for IPv6 addresses. |
Usage Guidelines
Layer 3 interfaces, including VLAN interface, loopback interface, routed interface and sub- interface, share the same hardware resources. When configuring IP address, it is required that the IP addresses of different layer 3 interfaces in the same VRF cannot be in the same subnet; However, overlapped layer 3 interface addresses in different VRFs is supported.
Example
- Configure the IPv4 address for a routed interface.
admin@Xorplus# set interface gigabit-ethernet te-1/1/4 routed-interface enable true admin@Xorplus# set interface gigabit-ethernet te-1/1/4 routed-interface name rif-te4 admin@Xorplus# set l3-interface routed-interface rif-te4 address 10.10.0.1 prefix-length 24 admin@Xorplus# commit
- The following example configures the IPv6 address for the routed interface and then removes the L3 interface:
admin@Switch# set l3-interface routed-interface rif-te5 address 2001:1:1::1 prefix-length 64 admin@Switch# commit admin@Switch# delete l3-interface routed-interface rif-te5
Copyright © 2024 Pica8 Inc. All Rights Reserved.