Programmable or Smart Patch Panel for Ethernet (Network Patch Panel), Layer 1 Switch

More often than not, you end up in a situation where you are remotely working on a particular network topology and you want to pull or change cabling. In that case, you have to either go physically and change it or get someone else to do it for you. I always wanted to have a patch panel which could do it for me via clicks, as most of the time when I am really experimenting, it would be well past bedtime and I would have to wait impatiently till morning to reach office and change the cabling.

This is an attempt to do it using commodity hardware. This solution is based on Cisco Routers, however any platform which supports the required feature can do the job, as the software I wrote can work on different CLIs.  Code named as Magnetron, {{ The vacuum tube inside Microwave oven }}

Here is a Video explaining  basics/Demo.

Under the Hood –

This whole solution is based on  AToM – Any Transport over MPLS. RFC 4448.

Well, I am not doing MPLS  L2VPN here, rather the local cross Connect, or local XConnect. So no need of MPLS for a small deployment with single router. No LDP either.

I am not going to explain MPLS/AToM Basics here, Google is your friend. Here is what exactly I am doing here –

  1. AToM Local Xconnect – Between ethernet interfaces.
  2. Use VC Type 5 for AToM -> most platforms default to that, So it picks whatever is coming on the wire, as long as its a Ethernet frame. This provides CDP transparency
  3. Link Status -> or AC Status – This is done using AC Status VCCV TLV on a real MPLS AToM, but here its just local connect and it still works.

The  CLI on XR for AC status Propagation is

RP/0/RSP0/CPU0:router# configure
RP/0/RSP0/CPU0:router(config)# interface GigabitEthernet 0/0/0/0 
RP/0/RSP0/CPU0:router(config-if)# l2transport propagate remote remote-status
And for XE
pseudowire-class eompls
 encapsulation mpls
interface GigabitEthernet1/0/0
 xconnect 1 pw-class eompls
  remote link failure notification

Now to the Management Portal.  Its a simple Web  app written in LAMP Stack. Southbound cli to the router is done using  tcl/expect.


Source Code –   GitHub Link to be updated here soon – Reach out to me in case you want it before that.

Installation Steps – {{ TO be expanded Soon }}

Prepare the Linux/*nix VM/Server – Needs very basic installation with minimal hardware/VM Resources. Minimal CPU and Minimal Memory. Minimal Package Install.

Install Apache  –

Install PHP


Install expect/Tcl

Install my SQL/Maria DB & My SQL Php Connectors/Libraries

Create  DB, Tables, DB Users.

#mysql -u root -p
USE Magnetron2;
CREATE TABLE Magnetron_Nodes (id INT NOT NULL PRIMARY KEY AUTO_INCREMENT, NodeName varchar(30), NodePort  varchar(30), FabPort varchar(30) , STATE varchar(10)) ;
CREATE TABLE Magnetron_Fab (id INT NOT NULL PRIMARY KEY AUTO_INCREMENT, FabPortL varchar(30), FabPortR  varchar(30),ConStatus varchar (10)) ;

CREATE USER 'Magnetron2'@'localhost' IDENTIFIED BY 'Magnetron2';
GRANT ALL PRIVILEGES ON Magnetron2 . * TO 'Magnetron2'@'localhost';

copy the source code to /var/www/html folder or sub folder of your wish.

edit logindata.txt -> update router IP, username, Password.

Note: This release supports only IOS-XR Router as the central Node/Fabric Router. Support for IOS XE Coming soon.

You are all set and you can do –

http://<IP of your server/<folder>/index.php

and start playing around –

Back to Home Page for More Crazy Stuff







Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s