{"id":150,"date":"2015-09-01T21:32:56","date_gmt":"2015-09-01T21:32:56","guid":{"rendered":"http:\/\/wiki.thomasandsofia.com\/?p=150"},"modified":"2015-09-10T23:55:16","modified_gmt":"2015-09-10T23:55:16","slug":"ccent-3-s01-e15-lans-optimizing-and-troubleshooting-switches","status":"publish","type":"post","link":"https:\/\/wiki.thomasandsofia.com\/?p=150","title":{"rendered":"CCENT 3 S01 E15 \u2013 LANS: Optimizing and Troubleshooting Switches"},"content":{"rendered":"<h3>Configuring Speed and Duplex<\/h3>\n<p>By default both Speed and Duplex are set to &#8220;Auto&#8221;<br \/>\nAuto-detect Speed works every time.<br \/>\nAuto-detect Duplex can fail if both the switch and the device are set to auto detect.<\/p>\n<pre>DUPLEX MISMATCH: duplex mismatch discovered on FastEthernet 0\/1 (not half duplex), with AccessServer Ethernet (half duplex).<\/pre>\n<div class=\"warning\">You will only see these messages if you are directly connected to the monitor, or if you have &#8220;Terminal Monitor&#8221; enabled.<\/div>\n<p>&nbsp;<\/p>\n<h4>Symptoms<\/h4>\n<p>If one side sends &#8220;Full Duplex&#8221; and the other is only &#8220;Half Duplex&#8221;, there will be numerous collisions and everything will be slow.<\/p>\n<h4>Solution<\/h4>\n<p>Set the switchport listed in the error (0\/1) to match the device.<\/p>\n<pre>Sw1(config)#<span style=\"color: #00ffff;\">interface fastethernet 0\/1<\/span>\r\nSw1(config-if)#<span style=\"color: #00ffff;\">duplex half<\/span>\r\n%LINK-5-CHANGED: Interface FastEthernet0\/1, changed state to down\r\n%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0\/1, changed state to down\r\n%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to down\r\n%LINK-5-CHANGED: Interface FastEthernet0\/1, changed state to up\r\n%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0\/1, changed state to up\r\n%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up\r\n<\/pre>\n<h4>Set the Speed<\/h4>\n<pre>Sw1(config-if)#<span style=\"color: #00ffff;\">speed 10<\/span><\/pre>\n<p>&nbsp;<\/p>\n<h4>Recommendations<\/h4>\n<p>Allow PCs to &#8220;Auto Detect&#8221;<\/p>\n<p>Manually configure these to ensure the settings are correct.<\/p>\n<ul>\n<li>Servers<\/li>\n<li>Routers<\/li>\n<li>Printers<\/li>\n<li>Other Switches (using cross-over cables)<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3>Optimizing Your Switch<\/h3>\n<p>These probably won&#8217;t be on the test, but good to know (or at least to know about!)<\/p>\n<h4>Stop messages from splitting commands<\/h4>\n<p>Example:<\/p>\n<pre>Sw1#<span style=\"color: #00ffff;\">show<\/span>\r\n%SYS 5 CONFIG I: Configurd from console by thomas on vty0 (172.2.30.100) <span style=\"color: #00ffff;\">ip ...<\/span>\r\n<\/pre>\n<p>Commands for Console and Telnet:<\/p>\n<pre>Sw1(config)#<span style=\"color: #00ffff;\">line console 0<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">logging synchronous<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">exit<\/span>\r\nSw1(config)#<span style=\"color: #00ffff;\">line vty 0 4<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">logging synchronous<\/span>\r\n<\/pre>\n<p>Result:<\/p>\n<pre>Sw1#<span style=\"color: #00ffff;\">show<\/span>\r\n%SYS 5 CONFIG I: Configurd from console by thomas on vty0 (172.2.30.100)\r\nSw1#show <span style=\"color: #00ffff;\">ip ...<\/span>\r\n<\/pre>\n<p>&nbsp;<\/p>\n<h4>Setting the Idle Timer<\/h4>\n<p>By default the Idle Timer is set to 5 minutes.<br \/>\nExample: Set to 30 minutes and 0 seconds<\/p>\n<pre>Sw1(config)#<span style=\"color: #00ffff;\">line console 0<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">exec-timeout 30 0<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">exit<\/span>\r\nSw1(config)#<span style=\"color: #00ffff;\">line vty 0 4<\/span>\r\nSw1(config-line)#<span style=\"color: #00ffff;\">exec-timeout 30 <\/span>\r\n<\/pre>\n<p>To disable the timeout completely:<\/p>\n<pre>Sw1(config-line)#<span style=\"color: #00ffff;\">no exec timeout<\/span><\/pre>\n<p>&nbsp;<\/p>\n<h4>Fixing Typo Delays (Due to domain lookups)<\/h4>\n<p>If you enter a typo, the switch will try to locate the mis-typed word as a domain. This can cause long delays before the prompt is displayed<br \/>\nExample:<\/p>\n<pre>Sw1#<span style=\"color: #00ffff;\">flow<\/span>\r\nTranslating \"flow\"...domain server (255.255.255.255)\r\n...long delay!...\r\n% Unknown command or computer name, or unable to find computer address\r\nSw1#_\r\n<\/pre>\n<p>Command to disable this feature<\/p>\n<pre>Sw1(config)#<span style=\"color: #00ffff;\">no ip domain-lookup<\/span><\/pre>\n<p>Result:<\/p>\n<pre>Sw1#<span style=\"color: #00ffff;\">flow<\/span>\r\n% Unknown command or computer name, or unable to find computer address\r\nSw1#_\r\n<\/pre>\n<p>&nbsp;<\/p>\n<h4>Creating Aliases<\/h4>\n<p>Aliases may be create for the &#8220;Mode&#8221; you are in, so the same alias can mean different things depending on the operating mode<br \/>\nExample: Create Alias for Privilege Mode (Exec Mode)<\/p>\n<pre>Sw1(config)#<span style=\"color: #00ffff;\">alias exec s show ip interface brief<\/span><\/pre>\n<p>Result:<\/p>\n<pre>Sw1#<span style=\"color: #00ffff;\">s<\/span>\r\nInterfaces    IP Address       OK?  .....\r\nVlan1         172.2.30.180     YES  ..... \r\n...\r\n<\/pre>\n<p>&nbsp;<\/p>\n<h3>Spanning Tree Protocol<\/h3>\n<p>&#8220;Spanning Tree blocks redundancies to prevent loops.&#8221;<br \/>\nDesigned to prevent loops caused by broadcasts between multiple devices with redundant connections.<br \/>\nThis is known as a <b>Broadcast Storm<\/b><br \/>\n<a href=\"http:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-159\" src=\"http:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample.png\" alt=\"SpanningTreeFailExample\" width=\"314\" height=\"320\" srcset=\"https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample.png 314w, https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample-294x300.png 294w, https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample-147x150.png 147w, https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/SpanningTreeFailExample-300x306.png 300w\" sizes=\"auto, (max-width: 314px) 100vw, 314px\" \/><\/a><\/p>\n<p>Spanning Tree Protocol will drop trees on redundant links until they are needed.<\/p>\n<ul>\n<li>Blocks one link and monitors the active link to verify it is working<\/li>\n<li>Activates the blocked link if the primary link fails<\/li>\n<\/ul>\n<p>This gets quite complicated in real world setups!!!<br \/>\n<a href=\"http:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/complexnetworksetup.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-160\" src=\"http:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/complexnetworksetup.jpg\" alt=\"complexnetworksetup\" width=\"701\" height=\"616\" srcset=\"https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/complexnetworksetup.jpg 701w, https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/complexnetworksetup-300x264.jpg 300w, https:\/\/wiki.thomasandsofia.com\/wp-content\/uploads\/2015\/09\/complexnetworksetup-150x132.jpg 150w\" sizes=\"auto, (max-width: 701px) 100vw, 701px\" \/><\/a><\/p>\n<h3>Troubleshooting Using Show Commands<\/h3>\n<h4>show ip interface brief<\/h4>\n<p>Will provide a report of all interfaces on the switch, and their current status.<\/p>\n<pre>Sw1#show ip interface brief \r\nInterface              IP-Address      OK? Method Status                Protocol\r\nFastEthernet0\/1        unassigned      YES manual up                    up\r\nFastEthernet0\/2        unassigned      YES manual up                    up\r\nFastEthernet0\/3        unassigned      YES manual down                  down\r\nFastEthernet0\/4        unassigned      YES manual administratively down down\r\n...\r\nFastEthernet0\/23       unassigned      YES manual down                  down\r\nFastEthernet0\/24       unassigned      YES manual down                  down\r\nVlan1                  172.2.30.180    YES manual up\r\n<\/pre>\n<p>Status:Physical Layer<br \/>\nProtocol: Data Link Layer<\/p>\n<h4>show interface fastethernet 0\/N<\/h4>\n<pre>Sw1#<span style=\"color: #00ffff;\">show interface fastethernet 0\/2<\/span><\/pre>\n<pre>FastEthernet0\/2 is up, line protocol is up (connected)<\/pre>\n<p>FastEthernet0\/2 is up = Status (Physical Layer)<br \/>\nline protocol is up = Protocol (Data Link Layer)<\/p>\n<pre>  Hardware is Lance, address is 0001.c7d6.bb02 (<strong>bia<\/strong> 0001.c7d6.bb02)<\/pre>\n<p>bia = Built In Address = MAC address for the switchport<\/p>\n<pre> BW 100000 Kbit, DLY 1000 usec,\r\n     <strong>reliability<\/strong> 255\/255, <strong>txload<\/strong> 1\/255, <strong>rxload<\/strong> 1\/255<\/pre>\n<p>Reliability = 255\/255 = 100% Reliable = 1=0 &amp;&amp; 255=100<br \/>\ntxload = Transmitting Load: 1\/255 = very low, 255\/255 = full load<br \/>\nrxload = Receiving Load<\/p>\n<pre>  Encapsulation ARPA, loopback not set\r\n  Keepalive set (10 sec)\r\n  <strong>Full-duplex, 100Mb\/s<\/strong>\r\n  input flow-control is off, output flow-control is off\r\n  ARP type: ARPA, ARP Timeout 04:00:00\r\n  Last input 00:00:08, output 00:00:05, output hang never\r\n  Last clearing of \"show interface\" counters never\r\n  Input queue: 0\/75\/0\/0 (size\/max\/drops\/flushes); Total output drops: 0\r\n  Queueing strategy: fifo\r\n  Output queue :0\/40 (size\/max)\r\n  <strong>5 minute input rate 0 bits\/sec, 0 packets\/sec<\/strong>\r\n  <strong>5 minute output rate 0 bits\/sec, 0 packets\/sec<\/strong><\/pre>\n<p>The following information is Historical Data<\/p>\n<pre><strong>     956 packets<\/strong> input, 193351 bytes, 0 no buffer\r\n     Received <strong>956 broadcasts<\/strong>, 0 runts, 0 giants, 0 throttles<\/pre>\n<p>To calculate percentage of broadcasts: # Broadcasts \/ # Packets Input<br \/>\nAverage usually about 20%<br \/>\nRunts: Packets that are too small<br \/>\nGiants: Packets that are too large<br \/>\nRunts &amp; Giants generally caused by bad connections<\/p>\n<pre>     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort\r\n     0 watchdog, 0 multicast, 0 pause input\r\n     0 input packets with dribble condition detected\r\n     2357 packets output, 263570 bytes, 0 underruns\r\n     0 output errors, 0 collisions, 10 interface resets\r\n     0 babbles, 0 late collision, 0 deferred<\/pre>\n<p>Collisions generally caused by:<\/p>\n<ul>\n<li>Cable is too long<\/li>\n<li>Duplex mismatch (most common)<\/li>\n<\/ul>\n<p>Late Collisions may occur if # hops between src and dest is too great.<\/p>\n<ul>\n<li>This causes a packet to become delayed<\/li>\n<li>The Source resends the packet because it did not receive an ACK<\/li>\n<li>The new, repeat packet arrives<\/li>\n<\/ul>\n<p>0 lost carrier, 0 no carrier<br \/>\n0 output buffer failures, 0 output buffers swapped out<\/p>\n<p>&nbsp;<\/p>\n<h4>show running-config<\/h4>\n<p>Displays the actual configuration of the switch.<br \/>\nThis is essentially a list of all configuration commands being currently used.<\/p>\n<div class=\"warning\">During the Cisco test, it is common to have this command disabled to force you to use different commands to find the problem!<\/div>\n<p>&nbsp;<\/p>\n<pre>Sw1#show running-config\r\nBuilding configuration...\r\n\r\nCurrent configuration : 1386 bytes\r\n!\r\nversion 12.1\r\nno service timestamps log datetime msec\r\nno service timestamps debug datetime msec\r\nservice password-encryption\r\n!\r\nhostname Sw1\r\n!\r\nenable secret 5 $1$mERr$GvDaTJK9lhdXRUPWKA74O0\r\n!\r\nip ssh version 2\r\nip domain-name sw1.switch.com\r\n!\r\nusername thomas privilege 1 password 7 08314D5D1A0E0A0516\r\n!\r\nspanning-tree mode pvst\r\n!\r\ninterface FastEthernet0\/1\r\n switchport mode access\r\n switchport port-security\r\n!\r\ninterface FastEthernet0\/2\r\n switchport mode access\r\n!\r\ninterface FastEthernet0\/3\r\n!\r\n...\r\ninterface FastEthernet0\/22\r\n!\r\ninterface FastEthernet0\/23\r\n!\r\ninterface FastEthernet0\/24\r\n!\r\ninterface Vlan1\r\n ip address 172.2.30.180 255.255.255.0\r\n!\r\nip default-gateway 172.2.30.1\r\n!\r\nbanner motd ^C\r\n\r\n***\r\nKeep Out!\r\n***\r\n\r\n^C\r\n!\r\nline con 0\r\n password 7 08314D5D1A0E0A0516\r\n login\r\n!\r\nline vty 0 4\r\n exec-timeout 60 0\r\n password 7 08314D5D1A0E0A0516\r\n login\r\n transport input ssh\r\nline vty 5 15\r\n login\r\n!\r\n!\r\nend<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Configuring Speed and Duplex By default both Speed and Duplex are set to &#8220;Auto&#8221; Auto-detect Speed works every time. Auto-detect Duplex can fail if both the switch and the device are set to auto detect. DUPLEX MISMATCH: duplex mismatch discovered on FastEthernet 0\/1 (not half duplex), with AccessServer Ethernet (half duplex). You will only see ..<\/p>\n<div class=\"clear-fix\"><\/div>\n<p><a href=\"https:\/\/wiki.thomasandsofia.com\/?p=150\" title=\"read more...\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,2,5],"tags":[],"class_list":["post-150","post","type-post","status-publish","format-standard","hentry","category-ccent","category-networking","category-switches"],"_links":{"self":[{"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/posts\/150","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=150"}],"version-history":[{"count":16,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/posts\/150\/revisions"}],"predecessor-version":[{"id":245,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=\/wp\/v2\/posts\/150\/revisions\/245"}],"wp:attachment":[{"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=150"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=150"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wiki.thomasandsofia.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=150"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}