Skip to content

[memory_utilization] Fix memory check issue for container_autorestart and logrotate#22494

Merged
StormLiangMS merged 1 commit intosonic-net:masterfrom
lipxu:20260219_publicMaster_memoryCheck
Mar 3, 2026
Merged

[memory_utilization] Fix memory check issue for container_autorestart and logrotate#22494
StormLiangMS merged 1 commit intosonic-net:masterfrom
lipxu:20260219_publicMaster_memoryCheck

Conversation

@lipxu
Copy link
Contributor

@lipxu lipxu commented Feb 20, 2026

Description of PR

Summary:
Fixes # (issue)
36843474

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • New Test case
    • Skipped for non-supported platforms
  • Test case improvement

Back port request

  • 202205
  • 202305
  • 202311
  • 202405
  • 202411
  • 202505
  • 202511

Approach

What is the motivation for this PR?

autorestart/test_container_autorestart.py::test_containers_autorestart, this is a case related to the container restart, need to skip the memory checker during the test

simulate_small_var_log_partition memory checker collects memory before and after the case, so we need to make sure the test environment is stable before the case, it’s better to add the check for interface up and wait for bgp up in the fixture simulate_small_var_log_partition, config reload.
config_reload(duthost, safe_reload=True)
config_reload(duthost, safe_reload=True, check_intf_up_ports=True, wait_for_bgp=True)

How did you do it?

Skip the checker in autorestart/test_container_autorestart.py
Waiting device stable before testing

How did you verify/test it?

Any platform specific information?

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

Documentation

Signed-off-by: xuliping <xuliping@microsoft.com>
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@lipxu lipxu marked this pull request as ready for review March 2, 2026 08:12
@lipxu lipxu requested review from StormLiangMS and nhe-NV March 2, 2026 23:59
Copy link
Collaborator

@StormLiangMS StormLiangMS left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Collaborator

@StormLiangMS StormLiangMS left a comment

Choose a reason for hiding this comment

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

LGTM

@StormLiangMS StormLiangMS merged commit eb85d59 into sonic-net:master Mar 3, 2026
17 of 18 checks passed
aronovic pushed a commit to aronovic/sonic-mgmt that referenced this pull request Mar 3, 2026
…-net#22494)

What is the motivation for this PR?
autorestart/test_container_autorestart.py::test_containers_autorestart, this is a case related to the container restart, need to skip the memory checker during the test

simulate_small_var_log_partition memory checker collects memory before and after the case, so we need to make sure the test environment is stable before the case, it’s better to add the check for interface up and wait for bgp up in the fixture simulate_small_var_log_partition, config reload.
config_reload(duthost, safe_reload=True)
config_reload(duthost, safe_reload=True, check_intf_up_ports=True, wait_for_bgp=True)

How did you do it?
Skip the checker in autorestart/test_container_autorestart.py
Waiting device stable before testing
Signed-off-by: xuliping <xuliping@microsoft.com>
Signed-off-by: Mihut Aronovici <aronovic@cisco.com>
@lipxu lipxu added the Request for 202511 branch Request to backport a change to 202511 branch label Mar 3, 2026
rraghav-cisco pushed a commit to rraghav-cisco/sonic-mgmt that referenced this pull request Mar 3, 2026
…-net#22494)

What is the motivation for this PR?
autorestart/test_container_autorestart.py::test_containers_autorestart, this is a case related to the container restart, need to skip the memory checker during the test

simulate_small_var_log_partition memory checker collects memory before and after the case, so we need to make sure the test environment is stable before the case, it’s better to add the check for interface up and wait for bgp up in the fixture simulate_small_var_log_partition, config reload.
config_reload(duthost, safe_reload=True)
config_reload(duthost, safe_reload=True, check_intf_up_ports=True, wait_for_bgp=True)

How did you do it?
Skip the checker in autorestart/test_container_autorestart.py
Waiting device stable before testing
Signed-off-by: xuliping <xuliping@microsoft.com>
Signed-off-by: Raghavendran Ramanathan <rraghav@cisco.com>
mssonicbld pushed a commit to mssonicbld/sonic-mgmt that referenced this pull request Mar 3, 2026
…-net#22494)

What is the motivation for this PR?
autorestart/test_container_autorestart.py::test_containers_autorestart, this is a case related to the container restart, need to skip the memory checker during the test

simulate_small_var_log_partition memory checker collects memory before and after the case, so we need to make sure the test environment is stable before the case, it’s better to add the check for interface up and wait for bgp up in the fixture simulate_small_var_log_partition, config reload.
config_reload(duthost, safe_reload=True)
config_reload(duthost, safe_reload=True, check_intf_up_ports=True, wait_for_bgp=True)

How did you do it?
Skip the checker in autorestart/test_container_autorestart.py
Waiting device stable before testing
Signed-off-by: xuliping <xuliping@microsoft.com>
Signed-off-by: mssonicbld <sonicbld@microsoft.com>
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202511: #22715

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.

4 participants