Operation Manual
IP Services Commands
IP Services Commands
8 – 103
Syntax
set interface vlan-id ip {ip-addr mask | ip-addr/mask-length}
Defaults
None.
Access
Enabled.
History
Introduced in MSS Version 1.0.
Usage
You can assign one IP interface to each VLAN.
If an interface is already configured on the specified VLAN, this command replaces the interface.
If you replace an interface in use as the system IP address, replacing the interface can interfere
with system tasks that use the system IP address, including the following:
● Mobility domain operations
● Topology reporting for dual-homed MPs
● Default source IP address used in unsolicited communications such as AAA accounting reports
and SNMP traps
Examples
The following command configures IP interface 10.10.10.10/24 on VLAN default:
MX# set interface default ip 10.10.10.10/24
success: set ip address 10.10.10.10 netmask 255.255.255.0 on vlan default
The following command configures IP interface 10.10.20.10 255.255.255.0 on VLAN mauve:
MX# set interface mauve ip 10.10.20.10 255.255.255.0
success: set ip address 10.10.20.10 netmask 255.255.255.0 on vlan mauve
See Also
● clear interface on page 8-92
● set interface status on page 8-106
● show interface on page 8-135
set interface dhcp-client
Configures the DHCP client on a VLAN and allows the VLAN to obtain an IP interface from a
DHCP server.
Syntax
set interface vlan-id ip dhcp-client {enable | disable}
Defaults
The DHCP client is enabled by default on an unconfigured MXR-2 when the factory reset
switch is pressed and held during power on.
The DHCP client is disabled by default on all other MX models, and is disabled on an MXR-2 if it is
already configured, or the factory reset switch is not pressed and held during power on.
Access
Enabled.
vlan-id VLAN name or number.
ip-addr mask IP address and subnet mask in dotted decimal notation (for example, 10.10.10.10
255.255.255.0).
ip-addr/mask-length IP address and subnet mask length in CIDR format (for example, 10.10.10.10/
24).
vlan-id VLAN name or number.
enable Enables the DHCP client on the VLAN.
disable Disables the DHCP client on the VLAN.