Checking and setting the port speed on a Cisco switch

Learning that lasts. Online courses from $14.99

You can check the port speed on a Cisco network switch from its command-line interface (CLI) by logging into the switch and then issuing the show interface command. If you want to see the parameters, including port speed, for all ports on the switch, the command without any additional command line arguments will display information for all the ports on the switch. If you are only interested in the rate for a particular port, then specify it after the command. E.g., show interface fa0/1.

Cisco Computer Networking: The Fundamentals
Cisco Computer Networking: The Fundamentals
1px

 

Fundamentals of Cisco CLI Switch Configuration
Fundamentals of Cisco CLI Switch Configuration
1px;

Hadrian>show interfaces fa0/1
FastEthernet0/1 is up, line protocol is up (connected)
  Hardware is Fast Ethernet, address is 0009.e897.d281 (bia 0009.e897.d281)
  MTU 1500 bytes, BW 10000 Kbit, DLY 1000 usec,
     reliability 255/255, txload 32/255, rxload 1/255
  Encapsulation ARPA, loopback not set
  Keepalive set (10 sec)
  Full-duplex, 10Mb/s, media type is 100BaseTX
  input flow-control is unsupported output flow-control is unsupported
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input never, output 00:00:00, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/40 (size/max)
  5 minute input rate 72000 bits/sec, 29 packets/sec
  5 minute output rate 1286000 bits/sec, 728 packets/sec
     686444 packets input, 756803225 bytes, 0 no buffer
     Received 6 broadcasts (0 multicast)
     0 runts, 0 giants, 0 throttles
     4 input errors, 4 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog, 0 multicast, 0 pause input
     0 input packets with dribble condition detected
     1626390 packets output, 293258140 bytes, 0 underruns
     0 output errors, 0 collisions, 2 interface resets
     0 babbles, 0 late collision, 0 deferred
     0 lost carrier, 0 no carrier, 0 PAUSE output
     0 output buffer failures, 0 output buffers swapped out
Hadrian>

If you only want to see the port speed and not all of the additional information provided by the command, then you can filter the output so that you only see lines that include "Mb/s" as shown below.

Hadrian>show interfaces fa0/1 | include Mb/s
  Full-duplex, 10Mb/s, media type is 100BaseTX
Hadrian>

In the example above, the Fast Ethernet port Fa0/1 is set to 10 Mb/s though it is capable of 100 Mb/s connectivity. In this case, I know the device connected to the Fa0/1 port is connected to it by a 100 Mbs full duplex interface on that device, so I want to set the port on the Cisco switch to match so that data transmissions via the Fa0/1 port aren't unncessarily constrained to the slower 10 Mbs data transmission rate. I can change the rate to 100 Mbs by logging into the Cisco switch, changing to enable mode, issuing the configure terminal command, then specifying I want to configure the Fa0/1 port with the command interface fastethernet 0/1, and then specifying full-duplex communications and a speed of 100 Mbs as shown below. I can then exit from configuration mode by hitting the Cntrl and Z keys simultaneously and if I issue another show interface fa0/1 | include Mb/s command, I can see the port speed is now 100 Mb/s rather than 10 Mb/s. The device connected to the port should now be able to transmit and receive at 100 Mbs; no reboot of the switch is needed for the change to take effect.

User Access Verification

Password:
Hadrian>enable
Password:
Hadrian#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Hadrian(config)#interface fastethernet 0/1
Hadrian(config-if)#duplex full
Hadrian(config-if)#speed 100
Hadrian(config-if)#^Z
Hadrian#show interface fa0/1 | include Mb/s
  Full-duplex, 100Mb/s, media type is 100BaseTX
Hadrian#