diff --git a/src/sonic-config-engine/minigraph.py b/src/sonic-config-engine/minigraph.py index 74bfece3659e..c58201fdabd3 100644 --- a/src/sonic-config-engine/minigraph.py +++ b/src/sonic-config-engine/minigraph.py @@ -422,6 +422,7 @@ def parse_linkmeta(meta, hname): for linkmeta in link.findall(str(QName(ns1, "LinkMetadata"))): port = None fec_disabled = None + auto_negotiation = None # Sample: ARISTA05T1:Ethernet1/33;switch-t0:fortyGigE0/4 key = linkmeta.find(str(QName(ns1, "Key"))).text @@ -441,10 +442,14 @@ def parse_linkmeta(meta, hname): value = device_property.find(str(QName(ns1, "Value"))).text if name == "FECDisabled": fec_disabled = value + elif name == "AutoNegotiation": + auto_negotiation = value linkmetas[port] = {} if fec_disabled: linkmetas[port]["FECDisabled"] = fec_disabled + if auto_negotiation: + linkmetas[port]["AutoNegotiation"] = auto_negotiation return linkmetas @@ -638,6 +643,11 @@ def parse_xml(filename, platform=None, port_config_file=None): if port.get('speed') == '100000' and linkmetas.get(alias, {}).get('FECDisabled', '').lower() != 'true': port['fec'] = 'rs' + # If AutoNegotiation is available in the minigraph, we override any value we may have received from port_config.ini + autoneg = linkmetas.get(alias, {}).get('AutoNegotiation') + if autoneg: + port['autoneg'] = '1' if autoneg.lower() == 'true' else '0' + # set port description if parsed from deviceinfo for port_name in port_descriptions: # ignore port not in port_config.ini diff --git a/src/sonic-config-engine/tests/sample-arista-7050-t0-minigraph.xml b/src/sonic-config-engine/tests/sample-arista-7050-t0-minigraph.xml index 4fd1ba9ba128..4d216b30f203 100644 --- a/src/sonic-config-engine/tests/sample-arista-7050-t0-minigraph.xml +++ b/src/sonic-config-engine/tests/sample-arista-7050-t0-minigraph.xml @@ -462,12 +462,10 @@ - true DeviceInterface - true true 1 Ethernet5/1 @@ -480,7 +478,6 @@ DeviceInterface - true true 1 Ethernet6/1 @@ -493,7 +490,6 @@ DeviceInterface - true true 1 Ethernet7/1 @@ -506,7 +502,6 @@ DeviceInterface - true true 1 Ethernet8/1 @@ -519,7 +514,6 @@ DeviceInterface - true true 1 Ethernet9/1 @@ -532,7 +526,6 @@ DeviceInterface - true true 1 Ethernet10/1 @@ -545,7 +538,6 @@ DeviceInterface - true true 1 Ethernet11/1 @@ -558,7 +550,6 @@ DeviceInterface - true true 1 Ethernet12/1 @@ -571,7 +562,6 @@ DeviceInterface - true true 1 Ethernet13/1 @@ -584,7 +574,6 @@ DeviceInterface - true true 1 Ethernet14/1 @@ -597,7 +586,6 @@ DeviceInterface - true true 1 Ethernet15/1 @@ -610,7 +598,6 @@ DeviceInterface - true true 1 Ethernet16/1 @@ -623,7 +610,6 @@ DeviceInterface - true true 1 Ethernet17/1 @@ -636,7 +622,6 @@ DeviceInterface - true true 1 Ethernet18/1 @@ -649,7 +634,6 @@ DeviceInterface - true true 1 Ethernet19/1 @@ -662,7 +646,6 @@ DeviceInterface - true true 1 Ethernet20/1 @@ -675,7 +658,6 @@ DeviceInterface - true true 1 Ethernet21/1 @@ -688,7 +670,6 @@ DeviceInterface - true true 1 Ethernet22/1 @@ -701,7 +682,6 @@ DeviceInterface - true true 1 Ethernet23/1 @@ -714,7 +694,6 @@ DeviceInterface - true true 1 Ethernet24/1 @@ -727,7 +706,6 @@ DeviceInterface - true true 1 Ethernet25/1 @@ -740,7 +718,6 @@ DeviceInterface - true true 1 Ethernet26/1 @@ -753,7 +730,6 @@ DeviceInterface - true true 1 Ethernet27/1 @@ -766,7 +742,6 @@ DeviceInterface - true true 1 Ethernet28/1 @@ -779,7 +754,6 @@ DeviceInterface - true true 1 Ethernet29 @@ -792,7 +766,6 @@ DeviceInterface - true true 1 Ethernet30 @@ -805,7 +778,6 @@ DeviceInterface - true true 1 Ethernet31 @@ -818,7 +790,6 @@ DeviceInterface - true true 1 Ethernet32 @@ -831,7 +802,6 @@ DeviceInterface - true true 1 Ethernet33 @@ -844,7 +814,6 @@ DeviceInterface - true true 1 Ethernet34 @@ -857,7 +826,6 @@ DeviceInterface - true true 1 Ethernet35 @@ -870,7 +838,6 @@ DeviceInterface - true true 1 Ethernet36 @@ -902,6 +869,318 @@ + + + + + + + AutoNegotiation + + True + + + s7050-dev-1:Ethernet33;ARISTA01T1:Ethernet1 + + + + + + AutoNegotiation + + True + + + s7050-dev-1:Ethernet34;ARISTA02T1:Ethernet1 + + + + + + AutoNegotiation + + True + + + s7050-dev-1:Ethernet35;ARISTA03T1:Ethernet1 + + + + + + AutoNegotiation + + True + + + s7050-dev-1:Ethernet36;ARISTA04T1:Ethernet1 + + + + + + AutoNegotiation + + True + + + Servers0:eth0;s7050-dev-1:Ethernet6/1 + + + + + + AutoNegotiation + + True + + + Servers1:eth0;s7050-dev-1:Ethernet7/1 + + + + + + AutoNegotiation + + True + + + Servers2:eth0;s7050-dev-1:Ethernet8/1 + + + + + + AutoNegotiation + + True + + + Servers3:eth0;s7050-dev-1:Ethernet9/1 + + + + + + AutoNegotiation + + True + + + Servers4:eth0;s7050-dev-1:Ethernet10/1 + + + + + + AutoNegotiation + + True + + + Servers5:eth0;s7050-dev-1:Ethernet11/1 + + + + + + AutoNegotiation + + True + + + Servers6:eth0;s7050-dev-1:Ethernet12/1 + + + + + + AutoNegotiation + + True + + + Servers7:eth0;s7050-dev-1:Ethernet13/1 + + + + + + AutoNegotiation + + True + + + Servers8:eth0;s7050-dev-1:Ethernet14/1 + + + + + + AutoNegotiation + + True + + + Servers9:eth0;s7050-dev-1:Ethernet15/1 + + + + + + AutoNegotiation + + True + + + Servers10:eth0;s7050-dev-1:Ethernet16/1 + + + + + + AutoNegotiation + + True + + + Servers11:eth0;s7050-dev-1:Ethernet17/1 + + + + + + AutoNegotiation + + True + + + Servers12:eth0;s7050-dev-1:Ethernet18/1 + + + + + + AutoNegotiation + + True + + + Servers13:eth0;s7050-dev-1:Ethernet19/1 + + + + + + AutoNegotiation + + True + + + Servers14:eth0;s7050-dev-1:Ethernet20/1 + + + + + + AutoNegotiation + + True + + + Servers15:eth0;s7050-dev-1:Ethernet21/1 + + + + + + AutoNegotiation + + True + + + Servers16:eth0;s7050-dev-1:Ethernet22/1 + + + + + + AutoNegotiation + + True + + + Servers17:eth0;s7050-dev-1:Ethernet23/1 + + + + + + AutoNegotiation + + True + + + Servers18:eth0;s7050-dev-1:Ethernet24/1 + + + + + + AutoNegotiation + + True + + + Servers19:eth0;s7050-dev-1:Ethernet25/1 + + + + + + AutoNegotiation + + True + + + Servers20:eth0;s7050-dev-1:Ethernet26/1 + + + + + + AutoNegotiation + + True + + + Servers21:eth0;s7050-dev-1:Ethernet27/1 + + + + + + AutoNegotiation + + True + + + Servers22:eth0;s7050-dev-1:Ethernet28/1 + + + + + + AutoNegotiation + + True + + + Servers23:eth0;s7050-dev-1:Ethernet29/1 + + + s7050-dev-1 Arista-7050-QX-32S diff --git a/src/sonic-config-engine/tests/sample-dell-6100-t0-minigraph.xml b/src/sonic-config-engine/tests/sample-dell-6100-t0-minigraph.xml index 536a2c8a73c7..7cea7decfcc0 100644 --- a/src/sonic-config-engine/tests/sample-dell-6100-t0-minigraph.xml +++ b/src/sonic-config-engine/tests/sample-dell-6100-t0-minigraph.xml @@ -301,7 +301,6 @@ DeviceInterfaceLink - true 40000 ARISTA01T1 Ethernet1 @@ -311,7 +310,6 @@ DeviceInterfaceLink - true 40000 ARISTA01T1 Ethernet2 @@ -321,7 +319,6 @@ DeviceInterfaceLink - true 40000 ARISTA02T1 Ethernet1 @@ -331,7 +328,6 @@ DeviceInterfaceLink - true 40000 ARISTA02T1 Ethernet2 @@ -341,7 +337,6 @@ DeviceInterfaceLink - true 40000 ARISTA03T1 Ethernet1 @@ -351,7 +346,6 @@ DeviceInterfaceLink - true 40000 ARISTA03T1 Ethernet2 @@ -361,7 +355,6 @@ DeviceInterfaceLink - true 40000 ARISTA04T1 Ethernet1 @@ -371,7 +364,6 @@ DeviceInterfaceLink - true 40000 ARISTA04T1 Ethernet2 @@ -381,7 +373,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/7 @@ -391,7 +382,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/8 @@ -401,7 +391,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/9 @@ -411,7 +400,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/10 @@ -421,7 +409,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/11 @@ -431,7 +418,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/12 @@ -441,7 +427,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/13 @@ -451,7 +436,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/14 @@ -461,7 +445,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/15 @@ -471,7 +454,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/1/16 @@ -481,7 +463,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/1 @@ -491,7 +472,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/5 @@ -501,7 +481,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/6 @@ -511,7 +490,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/7 @@ -521,7 +499,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/8 @@ -531,7 +508,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/9 @@ -541,7 +517,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/10 @@ -551,7 +526,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/3/11 @@ -561,7 +535,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/7 @@ -571,7 +544,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/8 @@ -581,7 +553,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/9 @@ -591,7 +562,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/10 @@ -601,7 +571,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/11 @@ -611,7 +580,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/12 @@ -621,7 +589,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/13 @@ -631,7 +598,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/14 @@ -641,7 +607,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/15 @@ -651,7 +616,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/2/16 @@ -661,7 +625,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/1 @@ -671,7 +634,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/5 @@ -681,7 +643,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/6 @@ -691,7 +652,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/7 @@ -701,7 +661,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/8 @@ -711,7 +670,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/9 @@ -721,7 +679,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/10 @@ -731,7 +688,6 @@ DeviceInterfaceLink - true 40000 s6100-dev-1 fortyGigE1/4/11 @@ -765,6 +721,494 @@ + + + + + + + AutoNegotiation + + True + + + ARISTA01T1:Ethernet1;s6100-dev-1:fortyGigE1/1/1 + + + + + + AutoNegotiation + + True + + + ARISTA01T1:Ethernet2;s6100-dev-1:fortyGigE1/1/2 + + + + + + AutoNegotiation + + True + + + ARISTA02T1:Ethernet1;s6100-dev-1:fortyGigE1/1/5 + + + + + + AutoNegotiation + + True + + + ARISTA02T1:Ethernet2;s6100-dev-1:fortyGigE1/1/6 + + + + + + AutoNegotiation + + True + + + ARISTA03T1:Ethernet1;s6100-dev-1:fortyGigE1/2/1 + + + + + + AutoNegotiation + + True + + + ARISTA03T1:Ethernet2;s6100-dev-1:fortyGigE1/2/2 + + + + + + AutoNegotiation + + True + + + ARISTA04T1:Ethernet1;s6100-dev-1:fortyGigE1/2/5 + + + + + + AutoNegotiation + + True + + + ARISTA04T1:Ethernet2;s6100-dev-1:fortyGigE1/2/6 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-01:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/8;server-02:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-03:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-04:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-05:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-06:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-07:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-08:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-09:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/1/7;server-10:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/1;server-11:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/5;server-12:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/6;server-13:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/7;server-14:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/8;server-15:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/9;server-16:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/10;server-17:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/3/11;server-18:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/7;server-19:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/8;server-20:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/9;server-21:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/10;server-22:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/11;server-23:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/12;server-24:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/13;server-25:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/14;server-26:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/15;server-27:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/2/16;server-28:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/1;server-29:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/5;server-30:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/6;server-31:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/7;server-32:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/8;server-33:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/9;server-34:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/10;server-35:0 + + + + + + AutoNegotiation + + True + + + s6100-dev-1:fortyGigE1/4/11;server-36:0 + + + s6100-dev-1 Force10-S6100 - \ No newline at end of file + diff --git a/src/sonic-config-engine/tests/simple-sample-graph-case.xml b/src/sonic-config-engine/tests/simple-sample-graph-case.xml index 35d8f8343796..83becfd3b779 100644 --- a/src/sonic-config-engine/tests/simple-sample-graph-case.xml +++ b/src/sonic-config-engine/tests/simple-sample-graph-case.xml @@ -193,7 +193,6 @@ DeviceInterfaceLink - true 10000 switch-t0 fortyGigE0/0 @@ -220,6 +219,21 @@ + + + + + + + AutoNegotiation + + True + + + switch-01t1:port1;switch-t0:fortyGigE0/0 + + + @@ -265,12 +279,10 @@ - true DeviceInterface - true true 1 fortyGigE0/0 @@ -283,7 +295,6 @@ DeviceInterface - true true 1 fortyGigE0/4 @@ -296,7 +307,6 @@ DeviceInterface - true true 1 fortyGigE0/8 @@ -310,7 +320,6 @@ DeviceInterface - true true 1 fortyGigE0/12 @@ -329,7 +338,6 @@ DeviceInterface - true true 1 eth0 diff --git a/src/sonic-config-engine/tests/simple-sample-graph-metadata.xml b/src/sonic-config-engine/tests/simple-sample-graph-metadata.xml index 1b1da1ff1787..03eecc2b9dcb 100644 --- a/src/sonic-config-engine/tests/simple-sample-graph-metadata.xml +++ b/src/sonic-config-engine/tests/simple-sample-graph-metadata.xml @@ -250,12 +250,10 @@ - true DeviceInterface - true true 1 fortyGigE0/0 @@ -268,7 +266,6 @@ DeviceInterface - true true 1 fortyGigE0/4 @@ -281,7 +278,6 @@ DeviceInterface - true true 1 fortyGigE0/8 @@ -295,7 +291,6 @@ DeviceInterface - true true 1 fortyGigE0/12 @@ -314,7 +309,6 @@ DeviceInterface - true true 1 Management1 diff --git a/src/sonic-config-engine/tests/simple-sample-graph.xml b/src/sonic-config-engine/tests/simple-sample-graph.xml index 5ebbaafd9671..6c2c768e272f 100644 --- a/src/sonic-config-engine/tests/simple-sample-graph.xml +++ b/src/sonic-config-engine/tests/simple-sample-graph.xml @@ -223,7 +223,6 @@ DeviceInterfaceLink - true 1000 ARISTA01T1 et1 @@ -234,7 +233,6 @@ DeviceInterfaceLink - true 10000 switch-t0 fortyGigE0/1 @@ -245,7 +243,6 @@ DeviceInterfaceLink - true 10000 switch-t0 fortyGigE0/2 @@ -280,12 +277,10 @@ - true DeviceInterface - true true 1 fortyGigE0/0 @@ -298,7 +293,6 @@ DeviceInterface - true true 1 Ethernet1 @@ -311,7 +305,6 @@ DeviceInterface - true true 1 Ethernet2 @@ -324,7 +317,6 @@ DeviceInterface - true true 1 fortyGigE0/4 @@ -337,7 +329,6 @@ DeviceInterface - true true 1 fortyGigE0/8 @@ -351,7 +342,6 @@ DeviceInterface - true true 1 fortyGigE0/12 @@ -370,7 +360,6 @@ DeviceInterface - true 1 Management1 false diff --git a/src/sonic-config-engine/tests/t0-sample-autoneg-port-config.ini b/src/sonic-config-engine/tests/t0-sample-autoneg-port-config.ini new file mode 100644 index 000000000000..91555c6e111e --- /dev/null +++ b/src/sonic-config-engine/tests/t0-sample-autoneg-port-config.ini @@ -0,0 +1,33 @@ +# name lanes alias autoneg +Ethernet0 29,30,31,32 fortyGigE0/0 0 +Ethernet4 25,26,27,28 fortyGigE0/4 0 +Ethernet8 37,38,39,40 fortyGigE0/8 0 +Ethernet12 33,34,35,36 fortyGigE0/12 0 +Ethernet16 41,42,43,44 fortyGigE0/16 0 +Ethernet20 45,46,47,48 fortyGigE0/20 0 +Ethernet24 5,6,7,8 fortyGigE0/24 0 +Ethernet28 1,2,3,4 fortyGigE0/28 0 +Ethernet32 9,10,11,12 fortyGigE0/32 0 +Ethernet36 13,14,15,16 fortyGigE0/36 0 +Ethernet40 21,22,23,24 fortyGigE0/40 0 +Ethernet44 17,18,19,20 fortyGigE0/44 0 +Ethernet48 49,50,51,52 fortyGigE0/48 0 +Ethernet52 53,54,55,56 fortyGigE0/52 0 +Ethernet56 61,62,63,64 fortyGigE0/56 0 +Ethernet60 57,58,59,60 fortyGigE0/60 0 +Ethernet64 65,66,67,68 fortyGigE0/64 0 +Ethernet68 69,70,71,72 fortyGigE0/68 0 +Ethernet72 77,78,79,80 fortyGigE0/72 0 +Ethernet76 73,74,75,76 fortyGigE0/76 0 +Ethernet80 105,106,107,108 fortyGigE0/80 0 +Ethernet84 109,110,111,112 fortyGigE0/84 0 +Ethernet88 117,118,119,120 fortyGigE0/88 0 +Ethernet92 113,114,115,116 fortyGigE0/92 0 +Ethernet96 121,122,123,124 fortyGigE0/96 0 +Ethernet100 125,126,127,128 fortyGigE0/100 0 +Ethernet104 85,86,87,88 fortyGigE0/104 0 +Ethernet108 81,82,83,84 fortyGigE0/108 0 +Ethernet112 89,90,91,92 fortyGigE0/112 1 +Ethernet116 93,94,95,96 fortyGigE0/116 1 +Ethernet120 97,98,99,100 fortyGigE0/120 1 +Ethernet124 101,102,103,104 fortyGigE0/124 1 diff --git a/src/sonic-config-engine/tests/t0-sample-graph.xml b/src/sonic-config-engine/tests/t0-sample-graph.xml index 4ede44c852fe..adf3303f6217 100644 --- a/src/sonic-config-engine/tests/t0-sample-graph.xml +++ b/src/sonic-config-engine/tests/t0-sample-graph.xml @@ -380,7 +380,6 @@ DeviceInterfaceLink - true 100000 switch-t0 fortyGigE0/4 @@ -440,6 +439,11 @@ + + AutoNegotiation + + True + FECDisabled @@ -451,6 +455,11 @@ + + AutoNegotiation + + False + FECDisabled diff --git a/src/sonic-config-engine/tests/t1-sample-graph-mlnx.xml b/src/sonic-config-engine/tests/t1-sample-graph-mlnx.xml index 04fc88c34370..cc6f5e95940b 100644 --- a/src/sonic-config-engine/tests/t1-sample-graph-mlnx.xml +++ b/src/sonic-config-engine/tests/t1-sample-graph-mlnx.xml @@ -1745,12 +1745,10 @@ - true DeviceInterface - true true 1 Ethernet0 @@ -1763,7 +1761,6 @@ DeviceInterface - true true 1 Ethernet4 @@ -1776,7 +1773,6 @@ DeviceInterface - true true 1 Ethernet8 @@ -1789,7 +1785,6 @@ DeviceInterface - true true 1 Ethernet12 @@ -1802,7 +1797,6 @@ DeviceInterface - true true 1 Ethernet16 @@ -1815,7 +1809,6 @@ DeviceInterface - true true 1 Ethernet20 @@ -1828,7 +1821,6 @@ DeviceInterface - true true 1 Ethernet24 @@ -1841,7 +1833,6 @@ DeviceInterface - true true 1 Ethernet28 @@ -1854,7 +1845,6 @@ DeviceInterface - true true 1 Ethernet32 @@ -1867,7 +1857,6 @@ DeviceInterface - true true 1 Ethernet36 @@ -1880,7 +1869,6 @@ DeviceInterface - true true 1 Ethernet40 @@ -1893,7 +1881,6 @@ DeviceInterface - true true 1 Ethernet44 @@ -1906,7 +1893,6 @@ DeviceInterface - true true 1 Ethernet48 @@ -1919,7 +1905,6 @@ DeviceInterface - true true 1 Ethernet52 @@ -1932,7 +1917,6 @@ DeviceInterface - true true 1 Ethernet56 @@ -1945,7 +1929,6 @@ DeviceInterface - true true 1 Ethernet60 @@ -1958,7 +1941,6 @@ DeviceInterface - true true 1 Ethernet64 @@ -1971,7 +1953,6 @@ DeviceInterface - true true 1 Ethernet68 @@ -1984,7 +1965,6 @@ DeviceInterface - true true 1 Ethernet72 @@ -1997,7 +1977,6 @@ DeviceInterface - true true 1 Ethernet76 @@ -2010,7 +1989,6 @@ DeviceInterface - true true 1 Ethernet80 @@ -2023,7 +2001,6 @@ DeviceInterface - true true 1 Ethernet84 @@ -2036,7 +2013,6 @@ DeviceInterface - true true 1 Ethernet88 @@ -2049,7 +2025,6 @@ DeviceInterface - true true 1 Ethernet92 @@ -2062,7 +2037,6 @@ DeviceInterface - true true 1 Ethernet96 @@ -2075,7 +2049,6 @@ DeviceInterface - true true 1 Ethernet100 @@ -2088,7 +2061,6 @@ DeviceInterface - true true 1 Ethernet104 @@ -2101,7 +2073,6 @@ DeviceInterface - true true 1 Ethernet108 @@ -2114,7 +2085,6 @@ DeviceInterface - true true 1 Ethernet112 @@ -2127,7 +2097,6 @@ DeviceInterface - true true 1 Ethernet116 @@ -2140,7 +2109,6 @@ DeviceInterface - true true 1 Ethernet120 @@ -2153,7 +2121,6 @@ DeviceInterface - true true 1 Ethernet124 @@ -2235,6 +2202,362 @@ + + + + + + + AutoNegotiation + + True + + + ARISTA01T2:Ethernet1;arc-switch1026:Ethernet0 + + + + + + AutoNegotiation + + True + + + ARISTA02T2:Ethernet1;arc-switch1026:Ethernet4 + + + + + + AutoNegotiation + + True + + + ARISTA03T2:Ethernet1;arc-switch1026:Ethernet8 + + + + + + AutoNegotiation + + True + + + ARISTA04T2:Ethernet1;arc-switch1026:Ethernet12 + + + + + + AutoNegotiation + + True + + + ARISTA05T2:Ethernet1;arc-switch1026:Ethernet16 + + + + + + AutoNegotiation + + True + + + ARISTA06T2:Ethernet1;arc-switch1026:Ethernet20 + + + + + + AutoNegotiation + + True + + + ARISTA07T2:Ethernet1;arc-switch1026:Ethernet24 + + + + + + AutoNegotiation + + True + + + ARISTA08T2:Ethernet1;arc-switch1026:Ethernet28 + + + + + + AutoNegotiation + + True + + + ARISTA09T2:Ethernet1;arc-switch1026:Ethernet32 + + + + + + AutoNegotiation + + True + + + ARISTA10T2:Ethernet1;arc-switch1026:Ethernet36 + + + + + + AutoNegotiation + + True + + + ARISTA11T2:Ethernet1;arc-switch1026:Ethernet40 + + + + + + AutoNegotiation + + True + + + ARISTA12T2:Ethernet1;arc-switch1026:Ethernet44 + + + + + + AutoNegotiation + + True + + + ARISTA13T2:Ethernet1;arc-switch1026:Ethernet48 + + + + + + AutoNegotiation + + True + + + ARISTA14T2:Ethernet1;arc-switch1026:Ethernet52 + + + + + + AutoNegotiation + + True + + + ARISTA15T2:Ethernet1;arc-switch1026:Ethernet56 + + + + + + AutoNegotiation + + True + + + ARISTA16T2:Ethernet1;arc-switch1026:Ethernet60 + + + + + + AutoNegotiation + + True + + + ARISTA01T0:Ethernet1;arc-switch1026:Ethernet64 + + + + + + AutoNegotiation + + True + + + ARISTA02T0:Ethernet1;arc-switch1026:Ethernet68 + + + + + + AutoNegotiation + + True + + + ARISTA03T0:Ethernet1;arc-switch1026:Ethernet72 + + + + + + AutoNegotiation + + True + + + ARISTA04T0:Ethernet1;arc-switch1026:Ethernet76 + + + + + + AutoNegotiation + + True + + + ARISTA05T0:Ethernet1;arc-switch1026:Ethernet80 + + + + + + AutoNegotiation + + True + + + ARISTA06T0:Ethernet1;arc-switch1026:Ethernet84 + + + + + + AutoNegotiation + + True + + + ARISTA07T0:Ethernet1;arc-switch1026:Ethernet88 + + + + + + AutoNegotiation + + True + + + ARISTA08T0:Ethernet1;arc-switch1026:Ethernet92 + + + + + + AutoNegotiation + + True + + + ARISTA09T0:Ethernet1;arc-switch1026:Ethernet96 + + + + + + AutoNegotiation + + True + + + ARISTA10T0:Ethernet1;arc-switch1026:Ethernet100 + + + + + + AutoNegotiation + + True + + + ARISTA11T0:Ethernet1;arc-switch1026:Ethernet104 + + + + + + AutoNegotiation + + True + + + ARISTA12T0:Ethernet1;arc-switch1026:Ethernet108 + + + + + + AutoNegotiation + + True + + + ARISTA13T0:Ethernet1;arc-switch1026:Ethernet112 + + + + + + AutoNegotiation + + True + + + ARISTA14T0:Ethernet1;arc-switch1026:Ethernet116 + + + + + + AutoNegotiation + + True + + + ARISTA15T0:Ethernet1;arc-switch1026:Ethernet120 + + + + + + AutoNegotiation + + True + + + ARISTA16T0:Ethernet1;arc-switch1026:Ethernet124 + + + arc-switch1026 ACS-MSN2700 diff --git a/src/sonic-config-engine/tests/test_cfggen.py b/src/sonic-config-engine/tests/test_cfggen.py index d26277e3e46a..1e23019f2c3b 100644 --- a/src/sonic-config-engine/tests/test_cfggen.py +++ b/src/sonic-config-engine/tests/test_cfggen.py @@ -15,6 +15,7 @@ def setUp(self): self.sample_graph_bgp_speaker = os.path.join(self.test_dir, 't0-sample-bgp-speaker.xml') self.sample_device_desc = os.path.join(self.test_dir, 'device.xml') self.port_config = os.path.join(self.test_dir, 't0-sample-port-config.ini') + self.port_config_autoneg = os.path.join(self.test_dir, 't0-sample-autoneg-port-config.ini') def run_script(self, argument, check_stderr=False): print '\n Running sonic-cfggen ' + argument @@ -169,7 +170,82 @@ def test_minigraph_port_fec_disabled(self): # Test for FECDisabled argument = '-m "' + self.sample_graph_t0 + '" -p "' + self.port_config + '" -v "PORT[\'Ethernet4\']"' output = self.run_script(argument) - self.assertEqual(output.strip(), "{'lanes': '25,26,27,28', 'description': 'Servers0:eth0', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/4', 'admin_status': 'up', 'speed': '100000'}") + self.assertEqual(output.strip(), "{'lanes': '25,26,27,28', 'description': 'Servers0:eth0', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/4', 'admin_status': 'up', 'autoneg': '1', 'speed': '100000'}") + + def test_minigraph_port_autonegotiation(self): + # Test with a port_config.ini file which doesn't have an 'autoneg' column + argument = '-m "' + self.sample_graph_t0 + '" -p "' + self.port_config + '" -v "PORT"' + output = self.run_script(argument) + self.assertEqual(output.strip(), + "{'Ethernet8': {'lanes': '37,38,39,40', 'description': 'fortyGigE0/8', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/8', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet0': {'alias': 'fortyGigE0/0', 'pfc_asym': 'off', 'lanes': '29,30,31,32', 'description': 'fortyGigE0/0', 'mtu': '9100'}, " + "'Ethernet4': {'lanes': '25,26,27,28', 'description': 'Servers0:eth0', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/4', 'admin_status': 'up', 'autoneg': '1', 'speed': '100000'}, " + "'Ethernet108': {'alias': 'fortyGigE0/108', 'pfc_asym': 'off', 'lanes': '81,82,83,84', 'description': 'fortyGigE0/108', 'mtu': '9100'}, " + "'Ethernet100': {'alias': 'fortyGigE0/100', 'pfc_asym': 'off', 'lanes': '125,126,127,128', 'description': 'fortyGigE0/100', 'mtu': '9100'}, " + "'Ethernet104': {'alias': 'fortyGigE0/104', 'pfc_asym': 'off', 'lanes': '85,86,87,88', 'description': 'fortyGigE0/104', 'mtu': '9100'}, " + "'Ethernet68': {'lanes': '69,70,71,72', 'description': 'fortyGigE0/68', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/68', 'admin_status': 'up'}, " + "'Ethernet96': {'lanes': '121,122,123,124', 'description': 'fortyGigE0/96', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/96', 'admin_status': 'up'}, " + "'Ethernet124': {'lanes': '101,102,103,104', 'fec': 'rs', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/124', 'admin_status': 'up', 'speed': '100000', 'description': 'ARISTA04T1:Ethernet1/1'}, " + "'Ethernet92': {'lanes': '113,114,115,116', 'description': 'fortyGigE0/92', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/92', 'admin_status': 'up'}, " + "'Ethernet120': {'lanes': '97,98,99,100', 'description': 'ARISTA03T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/120', 'admin_status': 'up'}, " + "'Ethernet52': {'lanes': '53,54,55,56', 'description': 'fortyGigE0/52', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/52', 'admin_status': 'up'}, " + "'Ethernet56': {'lanes': '61,62,63,64', 'description': 'fortyGigE0/56', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/56', 'admin_status': 'up'}, " + "'Ethernet76': {'lanes': '73,74,75,76', 'description': 'fortyGigE0/76', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/76', 'admin_status': 'up'}, " + "'Ethernet72': {'lanes': '77,78,79,80', 'description': 'fortyGigE0/72', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/72', 'admin_status': 'up'}, " + "'Ethernet64': {'lanes': '65,66,67,68', 'description': 'fortyGigE0/64', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/64', 'admin_status': 'up'}, " + "'Ethernet32': {'lanes': '9,10,11,12', 'description': 'fortyGigE0/32', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/32', 'admin_status': 'up'}, " + "'Ethernet16': {'lanes': '41,42,43,44', 'description': 'fortyGigE0/16', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/16', 'admin_status': 'up'}, " + "'Ethernet36': {'lanes': '13,14,15,16', 'description': 'fortyGigE0/36', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/36', 'admin_status': 'up'}, " + "'Ethernet12': {'lanes': '33,34,35,36', 'description': 'fortyGigE0/12', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/12', 'admin_status': 'up'}, " + "'Ethernet88': {'lanes': '117,118,119,120', 'description': 'fortyGigE0/88', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/88', 'admin_status': 'up'}, " + "'Ethernet116': {'lanes': '93,94,95,96', 'description': 'ARISTA02T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/116', 'admin_status': 'up'}, " + "'Ethernet80': {'lanes': '105,106,107,108', 'description': 'fortyGigE0/80', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/80', 'admin_status': 'up'}, " + "'Ethernet112': {'lanes': '89,90,91,92', 'description': 'ARISTA01T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/112', 'admin_status': 'up'}, " + "'Ethernet84': {'lanes': '109,110,111,112', 'description': 'fortyGigE0/84', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/84', 'admin_status': 'up'}, " + "'Ethernet48': {'lanes': '49,50,51,52', 'description': 'fortyGigE0/48', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/48', 'admin_status': 'up'}, " + "'Ethernet44': {'lanes': '17,18,19,20', 'description': 'fortyGigE0/44', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/44', 'admin_status': 'up'}, " + "'Ethernet40': {'lanes': '21,22,23,24', 'description': 'fortyGigE0/40', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/40', 'admin_status': 'up'}, " + "'Ethernet28': {'lanes': '1,2,3,4', 'description': 'fortyGigE0/28', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/28', 'admin_status': 'up'}, " + "'Ethernet60': {'lanes': '57,58,59,60', 'description': 'fortyGigE0/60', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/60', 'admin_status': 'up'}, " + "'Ethernet20': {'lanes': '45,46,47,48', 'description': 'fortyGigE0/20', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/20', 'admin_status': 'up'}, " + "'Ethernet24': {'lanes': '5,6,7,8', 'description': 'fortyGigE0/24', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/24', 'admin_status': 'up'}}") + + # Test with a port_config.ini file which has an 'autoneg' column + argument = '-m "' + self.sample_graph_t0 + '" -p "' + self.port_config_autoneg + '" -v "PORT"' + output = self.run_script(argument) + self.assertEqual(output.strip(), + "{'Ethernet8': {'lanes': '37,38,39,40', 'description': 'fortyGigE0/8', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/8', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet0': {'lanes': '29,30,31,32', 'description': 'fortyGigE0/0', 'mtu': '9100', 'alias': 'fortyGigE0/0', 'pfc_asym': 'off', 'autoneg': '0'}, " + "'Ethernet4': {'lanes': '25,26,27,28', 'description': 'Servers0:eth0', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/4', 'admin_status': 'up', 'autoneg': '1', 'speed': '100000'}, " + "'Ethernet108': {'lanes': '81,82,83,84', 'description': 'fortyGigE0/108', 'mtu': '9100', 'alias': 'fortyGigE0/108', 'pfc_asym': 'off', 'autoneg': '0'}, " + "'Ethernet100': {'lanes': '125,126,127,128', 'description': 'fortyGigE0/100', 'mtu': '9100', 'alias': 'fortyGigE0/100', 'pfc_asym': 'off', 'autoneg': '0'}, " + "'Ethernet104': {'lanes': '85,86,87,88', 'description': 'fortyGigE0/104', 'mtu': '9100', 'alias': 'fortyGigE0/104', 'pfc_asym': 'off', 'autoneg': '0'}, " + "'Ethernet68': {'lanes': '69,70,71,72', 'description': 'fortyGigE0/68', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/68', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet96': {'lanes': '121,122,123,124', 'description': 'fortyGigE0/96', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/96', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet124': {'lanes': '101,102,103,104', 'fec': 'rs', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/124', 'admin_status': 'up', 'autoneg': '1', 'speed': '100000', 'description': 'ARISTA04T1:Ethernet1/1'}, " + "'Ethernet92': {'lanes': '113,114,115,116', 'description': 'fortyGigE0/92', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/92', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet120': {'lanes': '97,98,99,100', 'description': 'ARISTA03T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/120', 'admin_status': 'up', 'autoneg': '1'}, " + "'Ethernet52': {'lanes': '53,54,55,56', 'description': 'fortyGigE0/52', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/52', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet56': {'lanes': '61,62,63,64', 'description': 'fortyGigE0/56', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/56', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet76': {'lanes': '73,74,75,76', 'description': 'fortyGigE0/76', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/76', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet72': {'lanes': '77,78,79,80', 'description': 'fortyGigE0/72', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/72', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet64': {'lanes': '65,66,67,68', 'description': 'fortyGigE0/64', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/64', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet32': {'lanes': '9,10,11,12', 'description': 'fortyGigE0/32', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/32', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet16': {'lanes': '41,42,43,44', 'description': 'fortyGigE0/16', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/16', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet36': {'lanes': '13,14,15,16', 'description': 'fortyGigE0/36', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/36', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet12': {'lanes': '33,34,35,36', 'description': 'fortyGigE0/12', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/12', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet88': {'lanes': '117,118,119,120', 'description': 'fortyGigE0/88', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/88', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet116': {'lanes': '93,94,95,96', 'description': 'ARISTA02T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/116', 'admin_status': 'up', 'autoneg': '1'}, " + "'Ethernet80': {'lanes': '105,106,107,108', 'description': 'fortyGigE0/80', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/80', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet112': {'lanes': '89,90,91,92', 'description': 'ARISTA01T1:Ethernet1/1', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/112', 'admin_status': 'up', 'autoneg': '1'}, " + "'Ethernet84': {'lanes': '109,110,111,112', 'description': 'fortyGigE0/84', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/84', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet48': {'lanes': '49,50,51,52', 'description': 'fortyGigE0/48', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/48', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet44': {'lanes': '17,18,19,20', 'description': 'fortyGigE0/44', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/44', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet40': {'lanes': '21,22,23,24', 'description': 'fortyGigE0/40', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/40', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet28': {'lanes': '1,2,3,4', 'description': 'fortyGigE0/28', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/28', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet60': {'lanes': '57,58,59,60', 'description': 'fortyGigE0/60', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/60', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet20': {'lanes': '45,46,47,48', 'description': 'fortyGigE0/20', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/20', 'admin_status': 'up', 'autoneg': '0'}, " + "'Ethernet24': {'lanes': '5,6,7,8', 'description': 'fortyGigE0/24', 'pfc_asym': 'off', 'mtu': '9100', 'alias': 'fortyGigE0/24', 'admin_status': 'up', 'autoneg': '0'}}") def test_minigraph_port_rs(self): argument = '-m "' + self.sample_graph_t0 + '" -p "' + self.port_config + '" -v "PORT[\'Ethernet124\']"'