Management Interface in a Nondefault Instance

 

Why Use a Nondefault Management Interface

By default, in Junos OS, the management Ethernet interface (usually named fxp0 or em0) provides the out-of-band management network for the device. There is no clear separation between either out-of-band management traffic and in-band protocol control traffic, that is, user traffic at the routing-instance or routing-table level. Instead, all traffic is handled through the default routing instance, giving rise to concerns over security, performance, and how to troubleshoot.

Applications and Processes That Are VRF Aware

Starting with Junos OS Release 17.3R1, you can confine the management interface in a nondefault virtual routing and forwarding (VRF) instance, the mgmt_junos routing instance. After you configure this management routing instance as described in Configuring the mgmt_junos Routing Instance, management traffic no longer has to share a routing table (that is, the default.inet.0 table) with other control or protocol traffic in the system.

However, for the nondefault management instance to support all processes that communicate through the management interface, these processes must have support for a management VRF. In many cases, the new configuration to make these processes work with the nondefault VRF instance is to configure the name of the new management routing instance (mgmt_junos) for these processes. Information on how to configure mgmt_junos for the following processes is in the topics listed in the See Also section at the end of the list.

  • Automation scripts—Starting in Junos OS Release 18.1R1, configuration of commit, event, JET, op, and SNMP scripts is upgraded to support the nondefault management routing instance mgmt_junos as an option when specifying the source URL for refreshing or downloading Automation scripts. You can also specify some other routing instance (not a management instance) for refreshing or downloading Automation scripts.

  • BGP Monitoring Protocol (BMP)—Starting in Junos OS Release 18.3R1, a BMP station is now reachable over the management VRF instance.

  • Domain Name System (DNS)—Starting in Junos OS Release 19.2R1, you can route traffic between a dedicated management routing instance and DNS name server. When this configuration is set for at least for one name server, DNS resolution goes through.

  • NTP—Starting in Junos OS Release 18.1R1, NTP clients can support the nondefault management routing instance mgmt_junos when specifying the routing instance that is used to reach a server for NTP time synchronization.

  • RADIUS—Starting in Junos OS Release 18.1R1, we have enhanced the existing RADIUS support to include a management interface in a nondefault VRF instance.

  • syslog—In Junos OS Release 17.3R1, the syslog-event daemon was able to handle the dedicated management routing instance for IPv4 addressed remote host. As of Junos OS Release 18.1R1, the syslog-event daemon supports IPv6-based configuration when connecting to a remote host or an archival site, when the default management interface is moved to the dedicated management instance mgmt_junos. Statements at the [edit system syslog] hierarchy level support IPv6 addresses, too. Starting in Junos OS Release 18.4R1, you can configure the routing instance through which the remote server is reachable.

  • TACACS+Starting in Junos OS Release 17.4R1, existing TACACS+ behavior is enhanced to support a management interface in a nondefault VRF instance.

Configuring the mgmt_junos Routing Instance

Starting in Junos OS 17.3R1, you can confine the management interface in a dedicated management instance by configuring the management-instance configuration statement at the [edit system] hierarchy level. The name of the dedicated management instance is reserved and hardcoded as mgmt_junos; you are prevented from configuring any other routing instance by the name mgmt_junos. Once the mgmt_junos routing instance is deployed, management traffic no longer shares a routing table (that is, the default.inet.0 table) with other control or protocol traffic in the system, nor is configuring dynamic protocols on the management interface supported.

Because there are FreeBSD and Junos OS applications that assume that the management interface is always present in the default.inet.0 routing table, the mgmt_junos routing instance is not instantiated by default.

As part of configuring the mgmt_junos routing instance, you must also move static routes that have a next hop over the default management interface to the mgmt_junos routing instance. If needed, you must also configure the appropriate daemons or applications to use the mgmt_junos routing instance. All of these changes must be done in a single commit. Otherwise, the transition to mgmt_junos will not be smooth and you will have to repair the system later by logging in from the console.

After you commit the configuration, expect to lose, and then have to reestablish, the Telnet session.

For an example of using this feature, see the following sections:

Determining Static Routes

As part of configuring the mgmt_junos routing instance, you must move all the static routes that have a next hop through the default management interface from the default routing instance to mgmt_junos. The following commands are useful to determine static routes that need to be changed.

  • Use the show interfaces command to find the IP address of the default management interface:

    user@host> show interfaces fxp0 terse

    In this case the default management interface is fxp0, But it could be em0 or re0:mgmt-*.

  • Use the show route forwarding-table command to look at the forwarding table for next-hop information for static routes (static routes show up as type user):

    user@host> show route forwarding-table
  • Another way to find your static routes is to use the show route protocol static command.

    user@host> show route protocol static

Each setup is different. What you are identifying are the static routes that have a next hop through the fxp0 interface. The next hop for any static route that is affected will have an IP address that falls under the subnet of the IP address configured for fxp0.

Enabling the mgmt_junos Routing Instance

Note

Make sure to configure the mgmt_junos routing instance at the [edit routing-instances hierarchy level, for example:

To enable the mgmt_junos routing instance:

  1. Configure the management-instance statement.
  2. Move the appropriate static routes to the mgmt_junos routing instance.

    For a discussion of determining static routes to change, see Determining Static Routes.

    If you are using configuration groups you might want to set these changes as part of a group:

  3. Commit the configuration.

    Expect to lose the Telnet connection at commit.

  4. Reestablish the Telnet connection.

    At this point you have configured the management-instance statement. Tables for the mgmt_junos table are set up for inet and inet6 and marked as private tables. The management interface is moved to the mgmt_junos routing table. Static routes with a next hop to the management interface are moved from the default routing table and added to the mgmt_junos routing instance.

    However, if you have not configured the management routing-instance option in the tacplus server statement, the TACACS+ packets continue to be sent using the default routing instance only.

Removing the mgmt_junos Routing Instance

When you remove the mgmt_junos routing instance you must also move the static routes back to the default routing instance and delete the TACACS+ settings for mgmt_junos.

To remove the dedicated management interface:

  1. Delete or deactivate the management routing-instance statement.
  2. Move the static routes back to the default routing instance.

Related Documentation

Release History Table
Release
Description
Starting in Junos OS Release 17.4R1, existing TACACS+ behavior is enhanced to support a management interface in a nondefault VRF instance.
Starting with Junos OS Release 17.3R1, you can confine the management interface in a nondefault virtual routing and forwarding (VRF) instance, the mgmt_junos routing instance.