The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
Your software release
may not support all the features documented in this module. For the latest
caveats and feature information, see Bug Search Tool and the release notes for
your platform and software release. To find information about the features
documented in this module, and to see a list of the releases in which each
feature is supported, see the feature information table at the end of this
module.
Use Cisco Feature
Navigator to find information about platform support and Cisco software image
support. To access Cisco Feature Navigator, go to
http://www.cisco.com/go/cfn.
An account on Cisco.com is not required.
Restrictions for
Configuring Link-State Tracking
This feature is supported only on the LAN Base image.
You can
configure only two link-state groups per switch.
An interface
cannot be a member of more than one link-state group.
An interface
that is defined as an upstream interface in a link-state group cannot also be
defined as a downstream interface in the link-state group.
Do not enable
link-state tracking on individual interfaces that will part of a downstream
EtherChannel interface.
Understanding
Link-State Tracking
Link-state tracking,
also known as trunk failover, binds the link state of multiple interfaces.
Link-state tracking can be with server NIC adapter teaming to provide
redundancy in the network. When the server NIC adapters are configured in a
primary or secondary relationship, and the link is lost on the primary
interface, network connectivity is transparently changed to the secondary
interface.
To enable link-state tracking, create a link-state group, and
specify the interfaces that are assigned to the link-state group. An interface
can be an aggregation of ports (an EtherChannel), a single physical port in
access or trunk mode, or a routed port. In a link-state group, these interfaces
are bundled together. The downstream interfaces are bound to the upstream
interfaces. Interfaces connected to servers are referred to as downstream
interfaces, and interfaces connected to distribution switches and network
devices are referred to as upstream interfaces.
Note
An interface can be an aggregation of ports (an EtherChannel) or a
single physical port in either access or trunk mode .
The configuration in
this figure ensures that the network traffic flow is balanced.
For links to
switches and other network devices
Server 1 and
server 2 use switch A for primary links and switch B for secondary links.
Server 3 and
server 4 use switch B for primary links and switch A for secondary links.
Link-state group 1
on switch A
Switch A
provides primary links to server 1 and server 2 through link-state group 1.
Port 1 is connected to server 1, and port 2 is connected to server 2. Port 1
and port 2 are the downstream interfaces in link-state group 1.
Port 5 and
port 6 are connected to distribution switch 1 through link-state group 1. Port
5 and port 6 are the upstream interfaces in link-state group 1.
Link-state group 2
on switch A
Switch A
provides secondary links to server 3 and server 4 through link-state group 2.
Port 3 is connected to server 3, and port 4 is connected to server 4. Port 3
and port 4 are the downstream interfaces in link-state group 2.
Port 7 and
port 8 are connected to distribution switch 2 through link-state group 2. Port
7 and port 8 are the upstream interfaces in link-state group 2.
Link-state group 2
on switch B
Switch B
provides primary links to server 3 and server 4 through link-state group 2.
Port 3 is connected to server 3, and port 4 is connected to server 4. Port 3
and port 4 are the downstream interfaces in link-state group 2.
Port 5 and
port 6 are connected to distribution switch 2 through link-state group 2. Port
5 and port 6 are the upstream interfaces in link-state group 2.
Link-state group 1
on switch B
Switch B
provides secondary links to server 1 and server 2 through link-state group 1.
Port 1 is connected to server 1, and port 2 is connected to server 2. Port 1
and port 2 are the downstream interfaces in link-state group 1.
Port 7 and
port 8 are connected to distribution switch 1 through link-state group 1. Port
7 and port 8 are the upstream interfaces in link-state group 1.
In a link-state group,
the upstream ports can become unavailable or lose connectivity because the
distribution switch or router fails, the cables are disconnected, or the link
is lost. These are the interactions between the downstream and upstream
interfaces when link-state tracking is enabled:
If any of the
upstream interfaces are in the link-up state, the downstream interfaces can
change to or remain in the link-up state.
If all of the
upstream interfaces become unavailable, link-state tracking automatically puts
the downstream interfaces in the error-disabled state. Connectivity to and from
the servers is automatically changed from the primary server interface to the
secondary server interface. For example, in the previous figure, if the
upstream link for port 6 is lost, the link states of downstream ports 1 and 2
do not change. However, if the link for upstream port 5 is also lost, the link
state of the downstream ports changes to the link-down state. Connectivity to
server 1 and server 2 is then changed from link-state group1 to link-state
group 2. The downstream ports 3 and 4 do not change state because they are in
link-group 2.
If the link-state
group is configured, link-state tracking is disabled, and the upstream
interfaces lose connectivity, the link states of the downstream interfaces
remain unchanged. The server does not recognize that upstream connectivity has
been lost and does not failover to the secondary interface.
You can recover a
downstream interface link-down condition by removing the failed downstream port
from the link-state group. To recover multiple downstream interfaces, disable
the link-state group.
How to Configure
Link-State Tracking
To enable link-state
tracking, create a link-state group and specify the interfaces that are
assigned to the group. This task is optional.
SUMMARY STEPS
configure
terminal
link
state
tracknumber
interfaceinterface-id
link state group
[number] {upstream |
downstream}
end
DETAILED STEPS
Command or Action
Purpose
Step 1
configure
terminal
Example:
Switch# configure terminal
Enters global
configuration mode.
Step 2
link
state
tracknumber
Example:
Switch(config)# link state track 2
Creates a
link-state group and enables link-state tracking. The group number can be 1 or
2; the default is 1.
Step 3
interfaceinterface-id
Example:
Switch(config)# interface gigabitethernet2/0/1
Specifies a
physical interface or range of interfaces to configure, and enters interface
configuration mode.
Valid interfaces
include switch ports in access or trunk mode (IEEE 802.1q) or routed ports.
Note
Do not
enable link-state tracking on individual interfaces that will be part of an
Etherchannel interface.
Step 4
link state group
[number] {upstream |
downstream}
Example:
Switch(config-if)# link state group 2 upstream
Specifies a
link-state group and configures the interface as either an upstream or
downstream interface in the group.
Step 5
end
Example:
Switch(config-if)# end
Returns to
privileged EXEC mode.
Monitoring Link-State Tracking
You can display link-state tracking status using the command in this table.
Table 1. Commands for Monitoring Link-State Tracking Status
Command
Description
show link state group [number] [detail]
Displays the link-state group information.
Configuring Link-State Tracking: Example
This example shows how to create the link-state group 1 and configure the interfaces in the link-state group.
Switch# configure terminalSwitch(config)# link state track 1Switch(config-if)# interface range gigabitethernet1/0/21-22 Switch(config-if)# link state group 1 upstreamSwitch(config-if)# interface gigabitethernet1/0/1Switch(config-if)# link state group 1 downstreamSwitch(config-if)# interface gigabitethernet1/0/3Switch(config-if)# link state group 1 downstreamSwitch(config-if)# interface gigabitethernet1/0/5Switch(config-if)# link state group 1 downstreamSwitch(config-if)# end
The Cisco
Support website provides extensive online resources, including documentation
and tools for troubleshooting and resolving technical issues with Cisco
products and technologies.
To receive
security and technical information about your products, you can subscribe to
various services, such as the Product Alert Tool (accessed from Field Notices),
the Cisco Technical Services Newsletter, and Really Simple Syndication (RSS)
Feeds.
Access to
most tools on the Cisco Support website requires a Cisco.com user ID and
password.