Configuring the management interface

Prerequisites

A connection to the console port.

Procedure

  1. Switch to the management interface context with the commandinterface mgmt.
  2. By default, the management interface on the management port is enabled. If it was disabled, re-enable it with the command no shutdown.
  3. Use the command ip dhcp to configure the management interface to automatically obtain an address from a DHCP server on the network (factory default setting). Or, assign a static IPv4 or IPv6 address, default gateway, and DNS server with the commands ip address, ipv6 address, ip static, default-gateway, and nameserver.
  4. SSH is enabled by default on the management VRF. If disabled, enable SSH with the command ssh server vrf mgmt.

Examples

This example enables the management interface with dynamic addressing using DHCP:

switch(config)# interface mgmt switch(config-if-mgmt)# no shutdown switch(config-if-mgmt)# ip dhcp

This example enables the management interface with static addressing creating the following configuration:

  • Sets a static IPv4 address of 198.168.100.10 with a mask of 24 bits.
  • Sets the default gateway to 198.168.100.200.
  • Sets the DNS server to 198.168.100.201.
switch(config)# interface mgmt switch(config-if-mgmt)# no shutdown switch(config-if-mgmt)# ip static 198.168.100.10/24 switch(config-if-mgmt)# default-gateway 198.168.100.200 switch(config-if-mgmt)# nameserver 198.168.100.201