Skip to content

Fix errors in deploying dualtor-120.#3359

Merged
bingwang-ms merged 4 commits intosonic-net:masterfrom
bingwang-ms:various_fix_for_deploying
May 31, 2021
Merged

Fix errors in deploying dualtor-120.#3359
bingwang-ms merged 4 commits intosonic-net:masterfrom
bingwang-ms:various_fix_for_deploying

Conversation

@bingwang-ms
Copy link
Collaborator

@bingwang-ms bingwang-ms commented Apr 19, 2021

Description of PR

Summary:
This PR fixed several errors detected when deploying dualtor-120.

  1. Add missing dualtor-120 in ansible/veos and ansible/veos_vtb
  2. Shorten name template for interface to contain more digits.
  3. Add an argument topology for vm_topology library.

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • Test case(new/improvement)

Approach

What is the motivation for this PR?

This PR is to fix errors detected when deploying dualtor-120.

How did you do it?

Please see code.

How did you verify/test it?

Verified by deploying the newly defined dualtor-120.

Any platform specific information?

No.

Supported testbed topology if it's a new test case?

No.

Documentation

Signed-off-by: bingwang <bingwang@microsoft.com>
@bingwang-ms bingwang-ms requested a review from a team as a code owner April 19, 2021 05:51
# As a result, interface name like 'inje-vms21-6-132' will be invalid and rejected by kernel.
# Therefore, the name template is shorten to 3 bytes to contain more digits (3 in max)
INJECTED_INTERFACES_TEMPLATE = 'inj-%s-%d'
MUXY_INTERFACES_TEMPLATE = 'mux-%s-%d'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a disruptive change. This change will cause interface name change, so testbed deployed before this change cannot be removed after.
How do we deal with that?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the good catch. I also noticed that some other components that depend on the interface name or bridge name will fail.

Signed-off-by: bingwang <bingwang@microsoft.com>
@bingwang-ms
Copy link
Collaborator Author

bingwang-ms commented Apr 20, 2021

Update. I implemented an adaptive_name helper function to calculate interface and bridge name to ensure a valid length. And keep back compatible at the same time.

@yxieca
Copy link
Collaborator

yxieca commented Apr 21, 2021

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@bingwang-ms bingwang-ms merged commit ed6048a into sonic-net:master May 31, 2021
vmittal-msft pushed a commit to vmittal-msft/sonic-mgmt that referenced this pull request Sep 28, 2021
Adaptive interface/bridge name.

Signed-off-by: bingwang <bingwang@microsoft.com>
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.

4 participants