Sunday, June 19, 2011

The NX-OS 'spanning-tree port type edge' Interface Subcommand

N5K-01# sh vpc consistency-parameters global

    Legend:
        Type 1 : vPC will be suspended in case of mismatch

Name                        Type  Local Value            Peer Value
-------------               ----  ---------------------- -----------------------
QoS                         1     ([], [3], [], [], [],  ([], [3], [], [], [],
                                  [])                    [])
Network QoS (MTU)           1     (1538, 2240, 0, 0, 0,  (1538, 2240, 0, 0, 0,
                                  0)                     0)
Network Qos (Pause)         1     (F, T, F, F, F, F)     (F, T, F, F, F, F)
Input Queuing (Bandwidth)   1     (50, 50, 0, 0, 0, 0)   (50, 50, 0, 0, 0, 0)
Input Queuing (Absolute     1     (F, F, F, F, F, F)     (F, F, F, F, F, F)
Priority)
Output Queuing (Bandwidth)  1     (50, 50, 0, 0, 0, 0)   (50, 50, 0, 0, 0, 0)
Output Queuing (Absolute    1     (F, F, F, F, F, F)     (F, F, F, F, F, F)
Priority)
STP Mode                    1     Rapid-PVST             Rapid-PVST
STP Disabled                1     None                   None
STP MST Region Name         1     ""                     ""
STP MST Region Revision     1     0                      0
STP MST Region Instance to  1
 VLAN Mapping
STP Loopguard               1     Disabled               Disabled
STP Bridge Assurance        1     Enabled                Enabled
STP Port Type, Edge         1     Normal, Disabled,      Normal, Disabled,
BPDUFilter, Edge BPDUGuard        Disabled               Disabled
STP MST Simulate PVST       1     Enabled                Enabled
Allowed VLANs               -     10                     10
Local suspended VLANs       -     -                      -
N5K-01#
N5K-01# sh run int e1/8

!Command: show running-config interface Ethernet1/8
!Time: Wed Jun 15 07:35:28 2011

version 4.2(1)N2(1)

interface Ethernet1/8
  switchport access vlan 10
  speed 1000

N5K-01#
N5K-01# sh spanning-tree int e1/8 detail
ERROR: No spanning tree information available for Ethernet1/8

N5K-01#
N5K-01# ! Connect a laptop to E1/8
N5K-01# sh spanning-tree int e1/8 detail

 Port 136 (Ethernet1/8) of VLAN0010 is designated blocking
   Port path cost 4, Port priority 128, Port Identifier 128.136
   Designated root has priority 10, address 0021.565e.e200
   Designated bridge has priority 32778, address 0005.73af.fe7c
   Designated port id is 128.136, designated path cost 1
   Timers: message age 0, forward delay 12, hold 0
   Number of transitions to forwarding state: 0
   Link type is point-to-point by default
   BPDU: sent 1, received 0

N5K-01#
N5K-01# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg BLK 4         128.136  P2p

N5K-01#
N5K-01# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg BLK 4         128.136  P2p

N5K-01#
N5K-01# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg BLK 4         128.136  P2p

N5K-01#
N5K-01# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg LRN 4         128.136  P2p

N5K-01#
N5K-01# sh spanning-tree int e1/8 detail

 Port 136 (Ethernet1/8) of VLAN0010 is designated learning
   Port path cost 4, Port priority 128, Port Identifier 128.136
   Designated root has priority 10, address 0021.565e.e200
   Designated bridge has priority 32778, address 0005.73af.fe7c
   Designated port id is 128.136, designated path cost 1
   Timers: message age 0, forward delay 9, hold 0
   Number of transitions to forwarding state: 0
   Link type is point-to-point by default
   BPDU: sent 10, received 0

N5K-01#
N5K-01# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg FWD 4         128.136  P2p

N5K-01# sh spanning-tree int e1/8 detail

 Port 136 (Ethernet1/8) of VLAN0010 is designated forwarding
   Port path cost 4, Port priority 128, Port Identifier 128.136
   Designated root has priority 10, address 0021.565e.e200
   Designated bridge has priority 32778, address 0005.73af.fe7c
   Designated port id is 128.136, designated path cost 1
   Timers: message age 0, forward delay 0, hold 0
   Number of transitions to forwarding state: 1
   Link type is point-to-point by default
   BPDU: sent 19, received 0

N5K-01#
================================================================================
blocking - 15 seconds
learning - 15 seconds
================================================================================
N5K-01# conf t
Enter configuration commands, one per line.  End with CNTL/Z.
N5K-01(config)# int e1/8
N5K-01(config-if)# shut
N5K-01(config-if)# spanning-tree ?
  bpdufilter     Don't send or receive BPDUs on this interface
  bpduguard      Don't accept BPDUs on this interface
  cost           Change an interface's spanning tree port path cost
  guard          Change an interface's spanning tree guard mode
  link-type      Specify a link type for spanning tree tree protocol use
  mst            Multiple spanning tree configuration
  port           Spanning tree port options
  port-priority  Change an interface's spanning tree port priority
  vlan           VLAN Switch Spanning Trees

N5K-01(config-if)# spanning-tree port ?
  type  Specify a port type for spanning tree protocol use

N5K-01(config-if)# spanning-tree port type ?
  edge     Consider the interface as edge port (enable portfast)
  network  Consider the interface as inter-switch link
  normal   Consider the interface as normal spanning tree port

N5K-01(config-if)# spanning-tree port type edge ?
  <cr>
  trunk  Consider the interface as edge port (enable portfast) even in trunk
         mode

N5K-01(config-if)# spanning-tree port type edge
Warning: Edge port type (portfast) should only be enabled on ports connected to a single
 host. Connecting hubs, concentrators, switches, bridges, etc... to this
 interface  when edge port type (portfast) is enabled, can cause temporary bridging loops.
 Use with CAUTION

Edge Port Type (Portfast) has been configured on Ethernet1/8 but will only
 have effect when the interface is in a non-trunking mode.
N5K-01(config-if)#
N5K-01(config-if)# sh run int e1/8

!Command: show running-config interface Ethernet1/8
!Time: Wed Jun 15 07:38:47 2011

version 4.2(1)N2(1)

interface Ethernet1/8
  switchport access vlan 10
  spanning-tree port type edge
  speed 1000

N5K-01(config-if)#
N5K-01(config-if)# no shut
N5K-01(config-if)#
N5K-01(config-if)# sh spanning-tree int e1/8 detail

 Port 136 (Ethernet1/8) of VLAN0010 is designated forwarding
   Port path cost 4, Port priority 128, Port Identifier 128.136
   Designated root has priority 10, address 0021.565e.e200
   Designated bridge has priority 32778, address 0005.73af.fe7c
   Designated port id is 128.136, designated path cost 1
   Timers: message age 0, forward delay 0, hold 0
   Number of transitions to forwarding state: 1
   The port type is edge
   Link type is point-to-point by default
   BPDU: sent 10, received 0

N5K-01(config-if)#
N5K-01(config-if)# sh spanning-tree vlan 10

VLAN0010
  Spanning tree enabled protocol rstp
  Root ID    Priority    10
             Address     0021.565e.e200
             Cost        1
             Port        4096 (port-channel1)
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     0005.73af.fe7c
             Hello Time  2  sec  Max Age 20 sec  Forward Delay 15 sec

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Po1              Root FWD 1         128.4096 (vPC) P2p Peer(STP)
Po10             Desg FWD 1         128.4105 (vPC peer-link) Network P2p
Eth1/8           Desg FWD 4         128.136  Edge P2p

N5K-01(config-if)#

Note: The NX-OS spanning-tree port type edge [trunk] interface subcommand is equivalent to the IOS spanning-tree portfast [trunk] interface subcommand.
The spanning-tree port type edge [trunk] interface subcommand is not available for N7K.

No comments:

Post a Comment