{"id":135,"date":"2020-05-27T22:07:16","date_gmt":"2020-05-27T22:07:16","guid":{"rendered":"https:\/\/www.vandervecken.com\/faucet\/?p=135"},"modified":"2020-05-27T22:07:16","modified_gmt":"2020-05-27T22:07:16","slug":"coprocessing-with-a-passive-loopback-cable","status":"publish","type":"post","link":"https:\/\/faucet.vandervecken.com\/index.php\/2020\/05\/27\/coprocessing-with-a-passive-loopback-cable\/","title":{"rendered":"Coprocessing with a passive loopback cable"},"content":{"rendered":"\n<p>This rather ugly, but dramatically lit little fellow is a passive loopback cable (I connected only two pairs, so it can do only 100MB).<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.vandervecken.com\/faucet\/wp-content\/uploads\/2020\/05\/loop1-1024x458.jpg\" alt=\"\" class=\"wp-image-136\" width=\"517\" height=\"231\" srcset=\"https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-1024x458.jpg 1024w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-300x134.jpg 300w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-768x344.jpg 768w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-1536x687.jpg 1536w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-2048x916.jpg 2048w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/loop1-1568x701.jpg 1568w\" sizes=\"auto, (max-width: 517px) 100vw, 517px\" \/><\/figure>\n\n\n\n<p>Here it is installed in port 11 on this OpenFlow switch.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.vandervecken.com\/faucet\/wp-content\/uploads\/2020\/05\/installed1-1024x643.jpg\" alt=\"\" class=\"wp-image-137\" width=\"511\" height=\"321\" srcset=\"https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-1024x643.jpg 1024w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-300x188.jpg 300w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-768x483.jpg 768w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-1536x965.jpg 1536w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-2048x1287.jpg 2048w, https:\/\/faucet.vandervecken.com\/wp-content\/uploads\/2020\/05\/installed1-1568x985.jpg 1568w\" sizes=\"auto, (max-width: 511px) 100vw, 511px\" \/><\/figure>\n\n\n\n<p>But why? What possible use is this beyond testing that the physical interface works?<\/p>\n\n\n\n<p>Some OpenFlow switch implementations are based on hardware that predates the SDN era. In other words, some of that hardware just isn&#8217;t very programmable. There are limits on what actions some hardware can perform, and in some cases even the number of actions. If you need more than that &#8211; well &#8211; tough luck, it can&#8217;t be done (or it can only be done in software).<\/p>\n\n\n\n<p>What if you can spare a port though?<\/p>\n\n\n\n<p>That&#8217;s what we&#8217;re doing here. We&#8217;re using a coprocessing port to send packets out the loopback. As they come back, they hit a FAUCET ACL which allows further processing. The round trip buys us a bigger action budget &#8211; we can spend actions on the way out, and on the way in again.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>acls:\n  pushit:\n  - rule:\n      actions:\n        output:\n          vlan_vid: 999\n          port: 24\ndps:\n  mydp:\n    interfaces:\n      11:\n        description: loopback\n        coprocessor:\n            strategy: vlan_vid\n        acls_in: &#91;pushit]\n        mirror:\n          - 13\n      13:\n        native_vlan: trusted\n      24:\n        tagged_vlans:\n        - trusted\n        - untrusted\n\n\n<\/code><\/pre>\n\n\n\n<p>Port 13 is a simple port with one native VLAN. Traffic to and from this port is mirrored to port 11 (the mirror operation consumes our hardware action budget). Those packets leave on port 11, are looped back to port 11, where they hit the pushit ACL. This ACL pushes a new VLAN, 999 and outputs to 24. That ACL also consumes the hardware action budget (so without the loopback we would not have have had the hardware resources to complete the entire operation).<\/p>\n\n\n\n<p>A perfect beautiful solution? No. But, an interesting way to make less capable hardware somewhat more programmable by adding more (completely passive) hardware.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This rather ugly, but dramatically lit little fellow is a passive loopback cable (I connected only two pairs, so it can do only 100MB). Here it is installed in port 11 on this OpenFlow switch. But why? What possible use is this beyond testing that the physical interface works? Some OpenFlow switch implementations are based &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/faucet.vandervecken.com\/index.php\/2020\/05\/27\/coprocessing-with-a-passive-loopback-cable\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Coprocessing with a passive loopback cable&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-135","post","type-post","status-publish","format-standard","hentry","category-uncategorised","entry"],"_links":{"self":[{"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/posts\/135","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/comments?post=135"}],"version-history":[{"count":1,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/posts\/135\/revisions"}],"predecessor-version":[{"id":138,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/posts\/135\/revisions\/138"}],"wp:attachment":[{"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/media?parent=135"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/categories?post=135"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/faucet.vandervecken.com\/index.php\/wp-json\/wp\/v2\/tags?post=135"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}