Skip to content

Update the static dns test case#11652

Merged
yxieca merged 1 commit intosonic-net:masterfrom
nhe-NV:update_static_dns
Feb 16, 2024
Merged

Update the static dns test case#11652
yxieca merged 1 commit intosonic-net:masterfrom
nhe-NV:update_static_dns

Conversation

@nhe-NV
Copy link
Contributor

@nhe-NV nhe-NV commented Feb 6, 2024

fix #11681

When do the dhclient, if not specify the management port, it will also do dhclient other port,and may cause some error msg. To avoid this, need to specify the management port when do the dhclient, and kill the deamon after the test finish.

Description of PR

Summary: To make the test could pass without any err msg
Fixes # (issue)

Type of change

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

Back port request

  • 201911
  • 202012
  • 202205
  • 202305
  • 202311

Approach

What is the motivation for this PR?

How did you do it?

How did you verify/test it?

Any platform specific information?

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

Documentation

When do the dhclient, if not specify the management port, it will also do dhclient other port,and may cause some error msg. To avoid this, need to specify the management port when do the dhclient, and kill the deamon after the test finish.
@liat-grozovik
Copy link
Collaborator

@oleksandrivantsiv please review and confirm this is fixes the issue seen on master

@yxieca yxieca self-assigned this Feb 16, 2024
@yxieca yxieca merged commit 3d2e73d into sonic-net:master Feb 16, 2024
mssonicbld pushed a commit to mssonicbld/sonic-mgmt that referenced this pull request Feb 22, 2024
When do the dhclient, if not specify the management port, it will also do dhclient other port,and may cause some error msg. To avoid this, need to specify the management port when do the dhclient, and kill the deamon after the test finish.
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202311: #11751

mssonicbld pushed a commit that referenced this pull request Feb 22, 2024
When do the dhclient, if not specify the management port, it will also do dhclient other port,and may cause some error msg. To avoid this, need to specify the management port when do the dhclient, and kill the deamon after the test finish.
def stop_dhclient(duthost):
yield

if os.path.exists(DHCLIENT_PID_FILE):
Copy link
Contributor

@byu343 byu343 Feb 20, 2024

Choose a reason for hiding this comment

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

@yxieca It is found by @Staphylo that this check runs on the test server, but should be on the DUT, which will make the cleanup of dhclient still not happen. This PR lets dhclient only started for MGMT_PORT which was also including many front panel ports before this PR; it can fix the original issue. @nhe-NV Still, can you please further fix the cleanup of the dhclient?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have fixed it in #11765

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

dns/static_dns introduces syslog errors affecting following tests for not closing dhclient after starting it

7 participants