How to shutdown / no shutdown an Interface on Cisco IOS XR
These are the commands for disabling and enabling an interface on Cisco IOS XR. Run them in interface configuration mode.
interface [INTERFACE_NAME]
shutdowninterface [INTERFACE_NAME]
no shutdown| Field | Value |
|---|---|
| [INTERFACE_NAME] | Specify the target interface name (e.g. GigabitEthernet0/0/0/0) |
Example: Configuring Interface shutdown
This example shuts down GigabitEthernet0/0/0/0.
RP/0/RP0/CPU0:IOX-XR#configure
Sat Aug 1 14:33:16.300 UTC
RP/0/RP0/CPU0:IOX-XR(config)#interface gigabitEthernet 0/0/0/0
RP/0/RP0/CPU0:IOX-XR(config-if)#shutdown
RP/0/RP0/CPU0:IOX-XR(config-if)#commit
Sat Aug 1 14:33:26.622 UTC
RP/0/RP0/CPU0:IOX-XR(config-if)#end
RP/0/RP0/CPU0:IOX-XR#Example: Configuring Interface no shutdown
This example sets no shutdown on GigabitEthernet0/0/0/0.
RP/0/RP0/CPU0:IOX-XR#configure
Sat Aug 1 14:34:45.321 UTC
RP/0/RP0/CPU0:IOX-XR(config)#interface gigabitEthernet 0/0/0/0
RP/0/RP0/CPU0:IOX-XR(config-if)#no shutdown
RP/0/RP0/CPU0:IOX-XR(config-if)#commit
Sat Aug 1 14:34:54.061 UTC
RP/0/RP0/CPU0:IOX-XR(config-if)#end
RP/0/RP0/CPU0:IOX-XR#Checking Interface State with show interfaces
You can check the state of an interface with the show interfaces command.
show interfaces [INTERFACE_NAME]| Field | Value |
|---|---|
| [INTERFACE_NAME] | Specify the interface name to check the state of (if omitted, all interfaces are shown) |
Example: Checking the shutdown State
When shutdown is configured, it is shown as administratively down.
RP/0/RP0/CPU0:IOX-XR#show interfaces gigabitEthernet 0/0/0/0
GigabitEthernet0/0/0/0 is administratively down, line protocol is administratively down
Interface state transitions: 2
Hardware is GigabitEthernet, address is 5254.0047.fbf7 (bia 5254.0047.fbf7)
Description: to GigabitEthernet0/0/0/0.xrd-1
Internet address is Unknown
MTU 1514 bytes, BW 1000000 Kbit (Max: 1000000 Kbit)
reliability 255/255, txload 0/255, rxload 0/255
Encapsulation ARPA,
Full-duplex, 1000Mb/s, unknown, link type is force-up
output flow control is off, input flow control is off
Carrier delay (up) is 10 msec
loopback not set,
-- snip --
RP/0/RP0/CPU0:IOX-XR#Example: Checking the no shutdown (Operating Normally) State
After no shutdown is configured, if the link is connected it is shown as up / up.
RP/0/RP0/CPU0:IOX-XR#show interfaces gigabitEthernet 0/0/0/0
GigabitEthernet0/0/0/0 is up, line protocol is up
Interface state transitions: 3
Hardware is GigabitEthernet, address is 5254.0047.fbf7 (bia 5254.0047.fbf7)
Description: to GigabitEthernet0/0/0/0.xrd-1
Internet address is Unknown
MTU 1514 bytes, BW 1000000 Kbit (Max: 1000000 Kbit)
reliability 255/255, txload 0/255, rxload 0/255
Encapsulation ARPA,
Full-duplex, 1000Mb/s, unknown, link type is force-up
output flow control is off, input flow control is off
Carrier delay (up) is 10 msec
loopback not set,
-- snip --
RP/0/RP0/CPU0:IOX-XR#Example: Checking the State When no shutdown Is Set but the Cable Is Not Connected
Even with no shutdown configured, if the carrier signal cannot be detected — for example because the cable is disconnected or no SFP is inserted — the interface is shown as is down, line protocol is down, unlike the shutdown state (note that administratively is not present).
RP/0/RP0/CPU0:IOX-XR#show interfaces gigabitEthernet 0/0/0/0
GigabitEthernet0/0/0/0 is down, line protocol is down
Interface state transitions: 2
Hardware is GigabitEthernet, address is 5254.0047.fbf7 (bia 5254.0047.fbf7)
Description: to GigabitEthernet0/0/0/0.xrd-1
Internet address is Unknown
MTU 1514 bytes, BW 1000000 Kbit (Max: 1000000 Kbit)
reliability 255/255, txload 0/255, rxload 0/255
Encapsulation ARPA,
Full-duplex, 1000Mb/s, unknown, link type is force-up
output flow control is off, input flow control is off
Carrier delay (up) is 10 msec
loopback not set,
-- snip --
RP/0/RP0/CPU0:IOX-XR#The first line, is up, line protocol is up, actually shows two separate states.
| Position | Meaning |
|---|---|
| First (is up / is down / is administratively down) | Layer 1 (physical) state. Reflects the shutdown/no shutdown configuration and carrier (line signal) detection status |
| Second (line protocol is up / down) | Layer 2 (data link) state. If the first is down, this also goes down accordingly |
Combining these two values lets you distinguish between different causes.
| First State | Second State | Meaning |
|---|---|---|
| administratively down | administratively down | Disabled by shutdown configuration |
| down | down | no shutdown is configured, but a carrier signal cannot be detected due to a disconnected cable, missing SFP, etc. |
| up | up | no shutdown is configured and the link is also up normally |
administratively down and down look similar at a glance, but the difference is that the former is caused by configuration (shutdown), while the latter is caused by a physical factor (disconnection, etc.). Checking show running-config alongside this lets you determine which is the cause.
Using the show interfaces brief command, you can check the state of all interfaces concisely, one line each.
RP/0/RP0/CPU0:IOX-XR#show interfaces brief
Sat Aug 1 14:36:32.883 UTC
Intf Intf LineP Encap MTU BW
Name State State Type (byte) (Kbps)
--------------------------------------------------------------------------------
Lo0 admin-down admin-down Loopback 1500 0
Nu0 up up Null 1500 0
Mg0/RP0/CPU0/0 admin-down admin-down ARPA 1514 1000000
Gi0/0/0/0 up up ARPA 1514 1000000
Gi0/0/0/1 down down ARPA 1514 1000000
Gi0/0/0/2 admin-down admin-down ARPA 1514 1000000
RP/0/RP0/CPU0:IOX-XR#Gi0/0/0/1 has no shutdown configured, but both Intf State and LineP State are down, suggesting a disconnected cable, missing SFP, or similar. Note that this has a different meaning from Gi0/0/0/2’s admin-down (shutdown configured).
Difference in How shutdown / no shutdown Appear in show running-config
When checking the configuration with show running-config, note that shutdown and no shutdown are displayed differently.
- When
shutdownis configured: ashutdownline is shown within the interface configuration - When
no shutdownis configured: ano shutdownline is not shown (the absence of the setting is treated as meaning the interface is enabled)
show running-config Example for the shutdown State
RP/0/RP0/CPU0:IOX-XR#show running-config interface gigabitEthernet 0/0/0/0
interface GigabitEthernet0/0/0/0
description to-IOS-XE
ipv4 address 10.0.0.1 255.255.255.252
shutdown
!
RP/0/RP0/CPU0:IOX-XR#show running-config Example for the no shutdown State
RP/0/RP0/CPU0:IOX-XR#show running-config interface gigabitEthernet 0/0/0/0
interface GigabitEthernet0/0/0/0
description to-IOS-XE
ipv4 address 10.0.0.1 255.255.255.252
!
RP/0/RP0/CPU0:IOX-XR#In the no shutdown state, the shutdown line itself does not exist, so only the other settings appear in show running-config.
When checking whether an interface has been unintentionally shut down, it’s a good idea to check whether shutdown appears in show running-config.