Skip to content
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

Merged
merged 1 commit into from
Feb 15, 2018

Conversation

vharish02
Copy link
Contributor

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 [email protected]

- 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)

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 <[email protected]>
@vharish02
Copy link
Contributor Author

@yxieca Can you please review the PR.

@lguohan
Copy link
Collaborator

lguohan commented Feb 10, 2018

@vharish02 , I think we need some sort of unit test for this.

@vharish02
Copy link
Contributor Author

@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' -%}
Copy link
Contributor

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?

Copy link
Contributor Author

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.

@yxieca yxieca merged commit 9959898 into sonic-net:master Feb 15, 2018
@lguohan lguohan mentioned this pull request Feb 6, 2021
4 tasks
lguohan pushed a commit that referenced this pull request Feb 6, 2021
…#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 <[email protected]>
lguohan added a commit to lguohan/sonic-buildimage that referenced this pull request Feb 9, 2021
* 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 <[email protected]>
lguohan pushed a commit that referenced this pull request Feb 12, 2021
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 <[email protected]>
stepanblyschak pushed a commit to stepanblyschak/sonic-buildimage that referenced this pull request May 10, 2021
…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 <[email protected]>
theasianpianist pushed a commit to theasianpianist/sonic-buildimage that referenced this pull request Feb 5, 2022
…sonic-net#1386)

Signed-off-by: Akhilesh Samineni <[email protected]>

Changes to clear the iptables NAT rules only which were added by NAT Mgr instead of flushing the all the NAT entries
mssonicbld added a commit that referenced this pull request Jun 8, 2024
…tically (#19242)

#### Why I did it
src/sonic-sairedis
```
* 10483502 - (HEAD -> master, origin/master, origin/HEAD) [saiproxy] Implement all APIs except bulk (#1386) (30 hours ago) [Kamil Cudnik]
```
#### How I did it
#### How to verify it
#### Description for the changelog
arun1355492 pushed a commit to arun1355492/sonic-buildimage that referenced this pull request Jul 26, 2024
…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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants