Friday, February 20, 2015

RSTP vs STP port States

The goal of RSTP is to improve STP convergence. The first step in achieving this was to deprecate some of the 802.1D port states.

Below is a table showing the three port states for RSTP compared to the five ports states of 802.1D STP.

Administrative State STP State (802.1D) RSTP State (802.1w)
Disabled Disabled Discarding
Enabled Blocking Discarding
Enabled Listening Discarding
Enabled Learning Learning
Enabled Forwarding Forwarding

Monday, February 16, 2015

Default STP(Spanning-Tree Protocol) port costs

Rehashing STP at the moment for CCIE studies and thought I'd make a quick note about the default STP port costs and how they've evolved with link speed increases over time.

Things to note with the table below:

  • The default costs used by Catalyst switches correspond to the 802.1D-1998 version of the standard if PVST(Per-Vlan Spanning-Tree) or Rapid-PVST(Rapid Per-Vlan Spanning-Tree) are used.
  • If MSTP (802.1s) is used then Catalyst switches use the default costs that correspond to the 802.1D-2004 version.
  • Just to make things a little more confusing PVST and Rapid-PVST can be forced into using 802.1D-2004 default port costs via the 'spanning-tree pathcost method long' global configuration command. By default PVST and Rapid-PVST use 'spanning-tree pathcost method short' which causes the switch to us the older revision of the costs(802.1D-1998).

    Juniper by default uses the 802.1D-2004 default port costs when either RSTP or MSTP is enabled on its switching equipment.

    Port Speed Pre-802.1D-1998 Cost 802.1D-1998 Cost* 802.1D-2004 Cost**
    10Mbps 100 100 2000000
    100Mbps 10 19 200000
    1000Mbps(1Gbps) 1 4 20000
    10000Mbps(10Gbps) 1 2 2000
    * Cisco Catalyst default for PVST and Rapid-PVST
    ** Juniper default for RSTP\MSTP & Cisco Catalyst default for MSTP

    Tuesday, September 30, 2014

    Checking memory allocation and usage on the fixed chassis MX devices (MX5,10,40 & 80)

    Usually when looking at memory distribution and usage on an MX modular based chassis device you would pull this from all FPCs installed. However the MX80 is an all in one unit(Fixed chassis) and the RE and PFE smarts are on the TFEB so therefore the only option when executing 'start shell pfe' is the TFEB.

    TFEB = T-Series Forwarding Engine Board


    This is also relevant to the MX5, 10 & 40 which share the same hardware as the MX80 but are throughput limited via software licensing.

    You can access the memory distribution and usage via two methods:


    user@mx80-1> start shell pfe network tfeb0          


    TFEB platform (1000Mhz MPC 8544 processor, 1024MB memory, 512KB flash)

    TAZ-TBB-0(mx80-1 vty)# show jnh 0 pool      
                    Name     MemType            Total         Used       (%)    Free       (%)

                Next Hop     EDMEM              2097152       1467484    69%    629668     31% 
                             IDMEM              299008        150528     50%    148480     50% 

                Firewall     EDMEM              2097152       67561      3%     2029591    97% 
                             IDMEM              274432        109874     40%    164558     60% 

                Counters     EDMEM              5242880       35228      < 1%   5207652    >99%
                             IDMEM              8192          3424       41%    4768       59% 

                    HASH     EDMEM              8486912       8486912    100%   0          0%  

                  ENCAPS     EDMEM              4259840       4259840    100%   0          0%  

                    LMEM     LMEM               512           67         13%    445        87% 

                    OMEM     OMEM               33079304      33079304   100%   0          0%  

              UEID_SPACE     0x01c00000         1048576       711        < 1%   1047865    >99%

       UEID_SHARED_SPACE     0x01bf0000         65536         10         < 1%   65526      >99%

    TAZ-TBB-0(mx80-1 vty)# 

    or just use the one liner from operational mode via 'request pfe execute':

    user@mx80-1> request pfe execute target tfeb0 command "show jnh 0 pool"  
    SENT: Ukern command: show jnh 0 pool
    GOT:
    GOT:                 Name     MemType            Total         Used       (%)    Free       (%)
    GOT:
    GOT:             Next Hop     EDMEM              2097152       1467484    69%    629668     31%
    GOT:                          IDMEM              299008        150528     50%    148480     50%
    GOT:
    GOT:             Firewall     EDMEM              2097152       67561      3%     2029591    97%
    GOT:                          IDMEM              274432        109874     40%    164558     60%
    GOT:
    GOT:             Counters     EDMEM              5242880       35228      < 1%   5207652    >99%
    GOT:                          IDMEM              8192          3424       41%    4768       59%
    GOT:
    GOT:                 HASH     EDMEM              8486912       8486912    100%   0          0%
    GOT:
    GOT:               ENCAPS     EDMEM              4259840       4259840    100%   0          0%
    GOT:
    GOT:                 LMEM     LMEM               512           67         13%    445        87%
    GOT:
    GOT:                 OMEM     OMEM               33079304      33079304   100%   0          0%
    GOT:
    GOT:           UEID_SPACE     0x01c00000         1048576       711        < 1%   1047865    >99%
    GOT:
    GOT:    UEID_SHARED_SPACE     0x01bf0000         65536         10         < 1%   65526      >99%

    Handy commands to know when executing CLI based audits of your nodes. Although variable monitoring would be much better for baseline and analysis purposes, so go set that up now!