--- /dev/null
+<!DOCTYPE html>
+<html dir="ltr" class="client-js" lang="en"><head>
+<meta http-equiv="content-type" content="text/html; charset=UTF-8">
+<meta charset="UTF-8">
+<title>Switches and ports - COWiki</title>
+
+<link rel="stylesheet" href="Switches%20and%20ports%20-%20COWiki_files/load.css">
+<style>
+.mw-collapsible-toggle{float:right;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none} .mw-content-ltr .mw-collapsible-toggle,.mw-content-rtl .mw-content-ltr .mw-collapsible-toggle{float:right} .mw-content-rtl .mw-collapsible-toggle,.mw-content-ltr .mw-content-rtl .mw-collapsible-toggle{float:left}.mw-customtoggle,.mw-collapsible-toggle{cursor:pointer} caption .mw-collapsible-toggle,.mw-content-ltr caption .mw-collapsible-toggle,.mw-content-rtl caption .mw-collapsible-toggle,.mw-content-rtl .mw-content-ltr caption .mw-collapsible-toggle,.mw-content-ltr .mw-content-rtl caption .mw-collapsible-toggle{float:none} li .mw-collapsible-toggle,.mw-content-ltr li .mw-collapsible-toggle,.mw-content-rtl li .mw-collapsible-toggle,.mw-content-rtl .mw-content-ltr li .mw-collapsible-toggle,.mw-content-ltr .mw-content-rtl li .mw-collapsible-toggle{float:none} .mw-collapsible-toggle-li{list-style:none}
+.suggestions{overflow:hidden;position:absolute;top:0;left:0;width:0;border:none;z-index:1099;padding:0;margin:-1px 0 0 0}.suggestions-special{position:relative;background-color:white;cursor:pointer;border:solid 1px #aaaaaa;padding:0;margin:0;margin-top:-2px;display:none;padding:0.25em 0.25em;line-height:1.25em}.suggestions-results{background-color:white;cursor:pointer;border:solid 1px #aaaaaa;padding:0;margin:0}.suggestions-result{color:black;margin:0;line-height:1.5em;padding:0.01em 0.25em;text-align:left; overflow:hidden;-o-text-overflow:ellipsis; text-overflow:ellipsis;white-space:nowrap}.suggestions-result-current{background-color:#4C59A6;color:white}.suggestions-special .special-label{color:gray;text-align:left}.suggestions-special .special-query{color:black;font-style:italic;text-align:left}.suggestions-special .special-hover{background-color:silver}.suggestions-result-current .special-label,.suggestions-result-current .special-query{color:white}.highlight{font-weight:bold}
+@media screen {
+ .tochidden,.toctoggle{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.toctoggle{font-size:94%}}
+@media print {
+ #toc.tochidden,.toctoggle{display:none}}
+.postedit-container{margin:0 auto;position:fixed;top:0;height:0;left:50%;z-index:1000;font-size:13px}.postedit-container:hover{cursor:pointer}.postedit{position:relative;top:0.6em;left:-50%;padding:.6em 3.6em .6em 1.1em;line-height:1.5625em;color:#626465;background-color:#f4f4f4;border:1px solid #dcd9d9;text-shadow:0 0.0625em 0 rgba(255,255,255,0.5);border-radius:5px;box-shadow:0 2px 5px 0 #ccc;-webkit-transition:all 0.25s ease-in-out;-moz-transition:all 0.25s ease-in-out;-ms-transition:all 0.25s ease-in-out;-o-transition:all 0.25s ease-in-out;transition:all 0.25s ease-in-out}.skin-monobook .postedit{top:6em !important}.postedit-faded{opacity:0}.postedit-icon{padding-left:41px; line-height:25px;background-repeat:no-repeat;background-position:8px 50%}.postedit-icon-checkmark{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAB9ElEQVR4AZWRA3AYURQArxrVHtW2bdu2bdu2zdi2bdu2bWxs7zeehZaw4f70kbs+zI3e/nWK+RWx3aOFlrL56Sy5SxrruG69hlv6OyK+mz+8KDSXdXembj0ispT7tjs4ZTIbpYBvxGSGKzZTeFrb7W/meN002swFs0U8ttpHTkF2BvCqWQrW35929bTsKm5Zb+SEwWwcY8wAngB9m7Z+d+rIPZ/npdy12M5p47n8dXsCYAf0qPy06eGMdktuDu9Qf+JmKl3SWM91qzVcN9tAbEYkwMaq0tyb1m/To5kP170el/BK8/qa6sJr70ydf+T/Uu5ab+Oo/lS0AkUBpIFWlZ9WPhxpse/PHO7YbOOczjL0vZV2lNxPPtG73dYXM+xvm2znrOl83tidoqCwMBgYXsPFB0on5S6pr+eK5TKuW67lgvaKvF8mL1dtfTL32FHxRdyx3cQpg7m4x9sCXKkTIzA4LDH44zWdzaUf71hv5rTG4uyzcusybxSX7aThbMQ8XgCYAp3rzTTQOiIh9PNlzY3FSuZxrzjme1Y7uGS6kjsWO4jPjM4FVjRZsvD4kO9XtTZzQn82NyzWc0B7AmZh6gA/hOYSGhfw9YbOVnarj+S7800AL2BIsxUAbWNToj7bhBuQmZcOsFdoKUC74rGheCwXmqAIQTc9jQcrADIAAAAASUVORK5CYII=);background-image:url(/resources/src/mediawiki.action/images/green-checkmark.png?d94f1)!ie;background-position:left}.postedit-close{position:absolute;padding:0 .8em;right:0;top:0;font-size:1.25em;font-weight:bold;line-height:2.3em;color:black;text-shadow:0 0.0625em 0 white;text-decoration:none;opacity:0.2;filter:alpha(opacity=20)}.postedit-close:hover{color:black;text-decoration:none;opacity:0.4;filter:alpha(opacity=40)}</style><style>
+.suggestions a.mw-searchSuggest-link,.suggestions a.mw-searchSuggest-link:hover,.suggestions a.mw-searchSuggest-link:active,.suggestions a.mw-searchSuggest-link:focus{color:black;text-decoration:none}.suggestions-result-current a.mw-searchSuggest-link,.suggestions-result-current a.mw-searchSuggest-link:hover,.suggestions-result-current a.mw-searchSuggest-link:active,.suggestions-result-current a.mw-searchSuggest-link:focus{color:white}.suggestions a.mw-searchSuggest-link .special-query{ overflow:hidden;-o-text-overflow:ellipsis; text-overflow:ellipsis;white-space:nowrap}</style><meta name="ResourceLoaderDynamicStyles" content="">
+</head>
+<body class="mediawiki ltr sitedir-ltr ns-0 ns-subject page-Switches_and_ports rootpage-Switches_and_ports skin-vector action-view">
+ <div id="mw-page-base" class="noprint"></div>
+ <div id="mw-head-base" class="noprint"></div>
+ <div id="content" class="mw-body" role="main">
+ <a id="top"></a>
+
+ <div class="mw-indicators">
+</div>
+ <h1 id="firstHeading" class="firstHeading" lang="en">Switches and ports</h1>
+ <div id="bodyContent" class="mw-body-content">
+ <div id="siteSub">From COWiki</div>
+ <div id="contentSub"></div>
+ <div id="jump-to-nav" class="mw-jump">
+ Jump to: <a href="#mw-head">navigation</a>, <a href="#p-search">search</a>
+ </div>
+ <div id="mw-content-text" dir="ltr" class="mw-content-ltr" lang="en"><div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2><span class="toctoggle"> [<a href="#" id="togglelink">hide</a>] </span></div>
+<ul>
+<li class="toclevel-1 tocsection-1"><a href="#Switches_and_Ports"><span class="tocnumber">1</span> <span class="toctext">Switches and Ports</span></a>
+<ul>
+<li class="toclevel-2 tocsection-2"><a href="#Connect_the_switch_to_a_serial_line"><span class="tocnumber">1.1</span> <span class="toctext">Connect the switch to a serial line</span></a></li>
+<li class="toclevel-2 tocsection-4"><a href="#What_is_connected_where.3F"><span class="tocnumber">1.3</span> <span class="toctext">What is connected where?</span></a></li>
+<li class="toclevel-2 tocsection-5"><a href="#The_switches.27_logs_and_other_debugging"><span class="tocnumber">1.4</span> <span class="toctext">The switches' logs and other debugging</span></a></li>
+<li class="toclevel-2 tocsection-6"><a href="#Adding_a_port_to_a_VLAN"><span class="tocnumber">1.5</span> <span class="toctext">Adding a port to a VLAN</span></a></li>
+<li class="toclevel-2 tocsection-7"><a href="#Spanning_tree"><span class="tocnumber">1.6</span> <span class="toctext">Spanning tree</span></a></li>
+<li class="toclevel-2 tocsection-8"><a href="#Transceivers.2C_modules.2C_links"><span class="tocnumber">1.7</span> <span class="toctext">Transceivers, modules, links</span></a></li>
+</ul>
+</li>
+<li class="toclevel-1 tocsection-9"><a href="#OLD.2C_unchecked.2C_maybe_out_of_date"><span class="tocnumber">2</span> <span class="toctext">OLD, unchecked, maybe out of date</span></a></li>
+</ul>
+</div>
+
+<h1><span class="mw-headline" id="Switches_and_Ports">Switches and Ports</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=1" title="Edit section: Switches and Ports">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
+<p>A quick guide to things you might want to do with an HP switch.
+</p>
+<h2><span class="mw-headline" id="Connect_the_switch_to_a_serial_line">Connect the switch to a serial line</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=2" title="Edit section: Connect the switch to a serial line">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p>Use a serial cable, and use 38400bps for HP switches. (Faster is
+possible but 38400 seems to be reliable.) Press Enter twice to get a
+login prompt. Username is <code>manager</code>, the password is the switch admin password.
+</p><p>You can use PuTTY (on Unix or Windows) to log in over a serial
+cable. If you attach a USB to serial adapter it will probably appear as <code>/dev/ttyUSB0</code> but <code>ls -l /dev/ttyUSB*</code> to check. By default Ubuntu restricts serial ports to group <code>dialout</code> so you may need to add yourself to that group.
+</p><p><a href="http://cowiki.maths.cam.ac.uk/index.php/File:Puttyserial.png" class="image" title="puttyserial.png"><img alt="puttyserial.png" src="Switches%20and%20ports%20-%20COWiki_files/Puttyserial.png" width="564" height="140"></a>
+</p>
+</p>
+
+<h2><span class="mw-headline" id="What_is_connected_where.3F">What is connected where?</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=4" title="Edit section: What is connected where?">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p>Switches keep track of what MAC address is seen on which port, so you can ask the switch.
+</p>
+<pre>show mac-address
+# but there'll be a lot of them on our switches
+show mac-address aa:bb:cc:dd:ee:ff
+# to show where that particular MAC address was seen or
+show mac-address B1
+# to show which MAC addresses were seen on port B1.
+show mac-address vlan 97
+# show only MAC addresses seen on VLAN 97.</pre>
+<p>Some things, mostly switches, advertise to the network what they are
+by a protocol called LLDP. You can ask questions about this to find out
+more about things that might be attached to your switch:
+</p>
+<pre>bl08-d1# show lldp info remote-device B24
+ LLDP Remote Device Information Detail
+ Local Port : B24
+ ChassisType : mac-address
+ ChassisId : aa bb cc dd ee ff
+ PortType : local
+ PortId : 50
+ SysName : blah-l2
+ System Descr : ProCurve J9088A Switch 2610-48, revision R.11.63, ROM R.1...
+ PortDescr : 50
+ Pvid :
+ System Capabilities Supported : bridge, router
+ System Capabilities Enabled : bridge
+ Remote Management Address
+ Type : ipv4
+ Address : 10.1.0.1
+blah-d1#</pre>
+<h2><span class="mw-headline" id="The_switches.27_logs_and_other_debugging">The switches' logs and other debugging</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=5" title="Edit section: The switches' logs and other debugging">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p><code>show log -r</code> to read the switch's log in reverse order with the most recent entries first.
+</p><p><code>/local/rancid</code> on monitor keeps copies of the
+configuration of our switches and notes on when they changed, so you may
+ be able to use this to discover when something changed.
+</p>
+<h2><span class="mw-headline" id="Adding_a_port_to_a_VLAN">Adding a port to a VLAN</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=6" title="Edit section: Adding a port to a VLAN">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p>Most VLANs we need to configure are <i>untagged</i>
+</p>
+<pre>config
+vlan 421 untagged B3
+exit
+wr mem</pre>
+<p>The final <code>wr mem</code> copies the running configuration to the switch's memory so it will startup with it.
+</p><p>To ask which ports are in a vlan or which vlans are on a port:
+</p>
+<pre>show vlans port A1
+show vlan 102</pre>
+<h2><span class="mw-headline" id="Spanning_tree">Spanning tree</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=7" title="Edit section: Spanning tree">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p>Hard to summarise just here, but:
+</p>
+<pre># to find out who is the root and see the state of all ports
+show spanning-tree
+# to find out which ports are receiving topology changes etc
+show spanning-tree debug-counters instance 0 ports all
+# (or ports A1, 1-4, etc.)
+# and look for topology changes Rx. If you're not expecting topology
+# changes from a switch you can then log on to that switch and repeat
+# the process
+# maybe you need to clear the counters so you can see changes more
+# clearly
+config
+spanning-tree clear-debug-counters</pre>
+<h2><span class="mw-headline" id="Transceivers.2C_modules.2C_links">Transceivers, modules, links</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="http://cowiki.maths.cam.ac.uk/index.php?title=Switches_and_ports&action=edit&section=8" title="Edit section: Transceivers, modules, links">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
+<p>Our chassis switches are modular, so you can ask which modules are in which slots and what their types and serial numbers are:
+</p>
+<pre>bl08-d1(config)# show modules
+ Status and Counters - Module Information
+ Chassis: 5412zl J8698A! Serial Number: XXXXXXXXXX
+ Allow V1 Modules: Yes
+ Management Module: J8726A Serial Number: XXXXXXXXXX Core Dump: YES
+ Core Mod
+ Slot Module Description Serial Number Status Dump Ver
+ ---- -------------------------------------- -------------- -------- ----- ---
+ A HP J9309A 4p 10-GbE SFP+ zl Module XXXXXXXXXX Up NO 1
+ B HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ C HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ D HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ E HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ F HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ G HP J8702A 24p Gig-T zl Module XXXXXXXXXX Up NO 1
+ I HP J9534A 24p Gig-T PoE+ v2 zl Module XXXXXXXXXX Up YES 2</pre>
+<p>You can hot-swap a module in slots A-L with another of the same type
+without rebooting the switch. If you insert a module of a different type
+ you will need to reboot the switch (<code>reload</code>) for it to work.
+</p><p>Fibre modules take little widgets called transceivers, SFP/SFP+ modules, or GBICs. To see which ones you have installed:
+</p>
+<pre>bl08-d1# show tech transceivers
+transceivers
+Transceiver Technical Information:
+ Port # | Type | Prod # | Serial # | Part #
+ -------+-----------+------------+------------------+----------
+ A1 | SFP+DA7 | J9285B | XXXXXXXXXX | 8121-1155
+ A2 | SFP+DA7 | J9285B | XXXXXXXXXX | 8121-1154
+ A3 | SFP+DA3 | J9283B | XXXXXXXXXX | 8121-1298</pre>
+</body></html>