Description

Disable and Deactivate interfaces on Junos are common misunderstandings that can lead to various problems while implementing changes on the network.
This article explains the difference between these two functionalities.

Solution

  • Deactivate is a Junos feature that deactivates configuration snippets and should NOT be confused with disabling or shutting down interfaces.
  • Deactivating a configuration on an interface will remove the effect of the configuration without removing it. However, it will keep the interface in UP state, which can impact routing and other functions for L2 and L3 protocols to detect the changes.
  • The Disable command should be used to take interfaces down and not deactivate.

Disabling an interface:

Disabling an interface in Junos is equivalent to interface shutdown. When using the Disable command, the interface will be administratively down without impacting the configuration on that interface.
Example output:
User@router> show interfaces ge-0/0/0 terse
Interface              Admin Link Proto   Local                Remote
ge-0/0/0               up   up
ge-0/0/0.0             up   up  inet    172.18.0.1/24

Notice interface is in UP UP state.


Disable interface configuration:

User@router> configure
User@router# set interfaces ge-0/0/0 disable
[edit]

The interface is taken down administratively. Notice the configuration (IP address) is still there indicated by unit 0.0:

User@router> show interfaces ge-0/0/0 terse
Interface              Admin Link   Proto   Local                Remote
ge-0/0/0               down   down
ge-0/0/0.0             up      down.  inet    172.18.0.1/24


Deactivate interface configuration:

The Deactivate command in Junos can be used with any configuration block or snippet and not explicitly tied to interfaces. When you deactivate a configuration, you remove that configuration's impact as if it is deleted without deleting it.

User@router> show interfaces ge-0/0/0 terse
Interface              Admin Link Proto   Local                Remote
ge-0/0/0                up    up
ge-0/0/0.0             up    up   inet    172.18.0.1/24

Deactivate the configuration:

User@router# deactivate interfaces ge-0/0/0
[edit]
User@router# commit

The configuration is no longer active, but the interface is still UP. Interface is in UP UP state:

User@router> show interfaces ge-0/0/0 terse
Interface              Admin Link Proto   Local                Remote
ge-0/0/0               up   up

Modification History

2021-06-09: Minor, non-technical edit.