-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[device/dell] Get Server ports from vlan config #1386
Conversation
This commit adds new support for dynamic buffer configuration. The cable_length macro is updated to return the cable length for server ports. Since the server ports are part of VLAN MEMBERS, the macro loops through the VLAN MEMBER ports and returns the cable length accordingly. If the port is not part of the SERVER port then it defaults to default cable length. The new code in the macro will be executed only if the switch is ToRRouter which is connected to the server on one side. Tested the code by loading minigraph configuration on the switch which had configuration for leaf-router as DEVICE NEIGHHOR and server ports in VLAN and ports which are not part of either server or leaf router. The dynamically generated buffer.json and config_db.json file had the cable_legnth updated accordingly for server ports with "5m" and leafrouter with "40m" and unconnected port to default "300m". The redis database also reflects the buffer profile's for 5m, 40m and 300m. Signed-off-by: Harish Venkatraman <Harish_Venkatraman@dell.com>
@yxieca Can you please review the PR. |
@vharish02 , I think we need some sort of unit test for this. |
@lguohan Yes I did run unit test for these changes. I have sent an email regarding that with logs attached. |
{%- for local_port in VLAN_MEMBER -%} | ||
{%- set vlan_port = local_port.split("|") -%} | ||
{%- if vlan_port[1] == port_name -%} | ||
{%- set roles3 = switch_role + '_' + 'server' -%} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you should check neighbor role first, acting accordingly, if the neighbor role is missing, then default to use vlan member v.s. non-vlan member, assuming non-vlan members are up links.
Can you elaborate why the vlan member were tested first?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yxieca As I explained to you the if check earlier takes care of the neighbor role and based on the neighbor role the cable length is taken. For the server side ports if the neighbor role is missing then we come to the else part where we check for the vlan members for those ports and get the correct cable length.
…#6701) sonic-swss: - [Mux] Route handling based on mux status, kernel tunnel support (#1615) - Reduce noise during frequent route update (#1624) - Changed Error log to Notice log during FDB flush notification after VLAN delete (#1618) - [PortsOrch] Add reference counting to ports for ACL bindings (#1614) - [crm]: Ignore unsupported/non-implemented switch attributes (#1613) - [Mux] Fix repeating logs in case of tunnel creation fail (#1610) sonic-utilities: - [config reload]: Restart mux container (#1401) - [storyteller] Enhance the storyteller utility (#1400) - [show] Fix int status when portchannel is in the system (#1376) - [config][show] cli support for retrieving ber, eye-info and configuring prbs, loopback on Y-cable (#1386) - Skip route check for tun0 interfaces (#1399) - do not parse stderr to get correct routing stack (#1398) - [storyteller] allow storyteller to work on downloaded logs (#1388) - [show] Run fwutil with sudo (#1364) Signed-off-by: Danny Allen <daall@microsoft.com>
* 270208b 2021-02-05 | [config reload]: Restart mux container (sonic-net#1401) (HEAD, origin/master, origin/HEAD) [Lawrence Lee] * e6cce21 2021-02-04 | Advertise ipv6 link local address (sonic-net#1402) [Sumukha Tumkur Vani] * a6e322a 2021-02-04 | [storyteller] Enhance the storyteller utility (sonic-net#1400) [Danny Allen] * 5cff775 2021-02-05 | [show] Fix int status when portchannel is in the system (sonic-net#1376) [Dmytro] * 9e0a4fa 2021-02-04 | [config][show] cli support for retrieving ber, eye-info and configuring prbs, loopback on Y-cable (sonic-net#1386) [vdahiya12] * 9ac47e5 2021-02-03 | Skip route check for tun0 interfaces (sonic-net#1399) [Prince Sunny] * ba68aed 2021-02-03 | do not parse stderr to get correct routing stack (sonic-net#1398) [lguohan] * aa7b90e 2021-02-03 | [storyteller] allow storyteller to work on downloaded logs (sonic-net#1388) [Ying Xie] * a6ae218 2021-02-02 | [vrf]: Fix freezing during interface binding (sonic-net#1325) [maksymbelei95] * 2e1f354 2021-02-01 | Use SonicV2Connector/ConfigDBConnector/SonicDBConfig from swsscommon instread of swsssdk (sonic-net#1392) [Qi Luo] Signed-off-by: Guohan Lu <lguohan@gmail.com>
sonic-utilities 28d358f...f5b8a1e (22): > Fix deprecation warnings (#1423) > Fix: initialize SonicDBConfig differently for single or multi_asic (continued) (#1417) > [multi-asic] show ip interface changes for multi asic (#1396) > [show mux]: Sort output by intf name (#1418) > [ci] Test and build package using Azure Pipelines (#1406) > [GitHub] Tweak PR and issue templates (#1419) > Import 'mock' module from 'unittest' library (#1415) > Revert "Add FW dump with new SAI implementation (#1338)" (#1407) > [config reload]: Restart macsec container (#1410) > [pcieutil] Remove the warning message and change the config file location (#1362) > Fix: initialize SonicDBConfig differently for single or multi_asic (#1409) > Support shared headroom pool on top of dynamic buffer calculation (#1348) > Fix unsupported fs.squashfs extraction in sonic-installer (#1366) > [show] Use proper variable to avoid exception in natshow script (#1383) > Set up CI with Azure Pipelines > [config reload]: Restart mux container (#1401) > Advertise ipv6 link local address (#1402) > [storyteller] Enhance the storyteller utility (#1400) > [show] Fix int status when portchannel is in the system (#1376) > [config][show] cli support for retrieving ber, eye-info and configuring prbs, loopback on Y-cable (#1386) > Skip route check for tun0 interfaces (#1399) > do not parse stderr to get correct routing stack (#1398) > [storyteller] allow storyteller to work on downloaded logs (#1388) > [vrf]: Fix freezing during interface binding (#1325) > Use SonicV2Connector/ConfigDBConnector/SonicDBConfig from swsscommon instread of swsssdk (#1392) Signed-off-by: Lawrence Lee <lawlee@microsoft.com>
…ng prbs, loopback on Y-cable (sonic-net#1386) This PR provides the support for adding CLI commands for configuring prbs, loopback and showing the BER and Eye info of the muxcable. In particular these Cli commands are supported: ` show muxcable eyeinfo <portnumber><target>` ` show muxcable berinfo <portnumber> <target>` `config muxcable prbs <portnumber> <target> <mode> <lanemap>` `config muxcable loopback <portnumber> <target> <lanemap>` #### What is the motivation for this PR? To add the support for Cli for muxcable to be utilized for configuring prbs, loopback modes and showing the ber, eye info of all the Port/Ports on a muxcable. Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
…sonic-net#1386) Signed-off-by: Akhilesh Samineni <akhilesh.samineni@broadcom.com> Changes to clear the iptables NAT rules only which were added by NAT Mgr instead of flushing the all the NAT entries
…tically (sonic-net#19242) #### Why I did it src/sonic-sairedis ``` * 10483502 - (HEAD -> master, origin/master, origin/HEAD) [saiproxy] Implement all APIs except bulk (sonic-net#1386) (30 hours ago) [Kamil Cudnik] ``` #### How I did it #### How to verify it #### Description for the changelog
This commit adds new support for dynamic buffer configuration. The cable_length macro is
updated to return the cable length for server ports. Since the server ports are part of
VLAN MEMBERS, the macro loops through the VLAN MEMBER ports and returns the cable length
accordingly. If the port is not part of the SERVER port then it defaults to default cable
length. The new code in the macro will be executed only if the switch is ToRRouter
which is connected to the server on one side.
Tested the code by loading minigraph configuration on the switch which had configuration
for leaf-router as DEVICE NEIGHHOR and server ports in VLAN and ports which are not part of
either server or leaf router. The dynamically generated buffer.json and config_db.json file
had the cable_legnth updated accordingly for server ports with "5m" and leafrouter with "40m"
and unconnected port to default "300m". The redis database also reflects the buffer profile's
for 5m, 40m and 300m.
Signed-off-by: Harish Venkatraman Harish_Venkatraman@dell.com
- What I did
- How I did it
- How to verify it
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)