Repository navigation
[AI Generated] Add NetShaper tool and MANA VF bandwidth-clamp validation - #4750
VENNELA2132 wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
Major cleanup, node-state, and unsupported-platform handling issues remain.
3 open findings
What changed in this PR
Adds a NetShaper tool and targeted MANA VF bandwidth-clamp validation.
Changes:
- Builds upstream iproute2 and exposes shaper operations.
- Adds MANA VF clamp validation and cleanup.
- Adds 17 unit tests.
| File | Description |
|---|---|
selftests/test_netshaper.py |
Tests commands, parsing, errors, and installation. |
lisa/tools/netshaper.py |
Implements the NetShaper tool. |
lisa/tools/__init__.py |
Exports NetShaper. |
lisa/microsoft/testsuites/network/sriov.py |
Adds MANA VF clamp validation. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Add a generic NetShaper tool backed by upstream iproute2 netshaper. - Build and install the latest upstream iproute2. - Expose GET, SET, and DELETE with explicit interface, scope, handle ID, and metric parameters. - Parse shaper readback, including bandwidth units and optional netdev IDs. - Distinguish absent shapers from command and parsing failures. - Skip when the kernel family or requested driver operation is unsupported. - Add unit coverage for commands, parsing, errors, and installation.
4f3bf0e to
7de1b9b
Compare
There was a problem hiding this comment.
🔵 Needs a closer look
Hardware-specific network mutation and runtime builds from upstream main require final human validation.
0 open findings
3 resolved since last review
🧠 Review effort: Balanced
Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.
Add single-node bandwidth-shaper validation for MANA VFs on Standard_ND128isr_NDR_GB200_v6. - Require Azure SR-IOV and select only MANA VF interfaces. - Configure netdev scope, handle ID 1, and bps inside the testcase. - Apply 100 Mbps and 1 Gbps caps and verify bandwidth readback. - Verify each bandwidth cap is applied successfully. - Delete each successfully applied cap in finally and verify its absence. - Use the normal SR-IOV suite setup and teardown.
7de1b9b to
1ab8053
Compare
|
Fixed the CI unittest-discovery import failure in 1ab8053 by using the package-qualified lisa.microsoft.testsuites.network.common import. All 23 focused tests now pass without the extension-only import path; Black, isort, flake8, mypy, and whitespace checks pass. Full local discovery ran 359 tests and no longer reports the SR-IOV import error, but encountered 15 Azure preparation errors involving AzurePlatform.credential. The pushed revision needs fresh CI results. |
There was a problem hiding this comment.
🟢 Approval recommended
The implementation is consistent with its stated scope and includes robust error handling and cleanup coverage.
Key Test Cases:
verify_sriov_netshaper_bandwidth_clamp
Impacted LISA Features:
NetworkInterface
Tested Azure Marketplace Images:
- canonical ubuntu-24_04-lts server-arm64 latest
- microsoftcblmariner azure-linux-3 azure-linux-3-arm64 latest
0 open findings
🧠 Review effort: Balanced
Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.
| @@ -0,0 +1,310 @@ | |||
| from decimal import Decimal | |||
There was a problem hiding this comment.
remove two selftests files

Summary
Add a generic NetShaper tool backed by upstream iproute2 and a single-node SR-IOV testcase for MANA VF bandwidth clamps on
Standard_ND128isr_NDR_GB200_v6.Changes
net_shaperfamily or the driver explicitly reports an unsupported operation.finallyand verify its absence.Validation
net_shaperfamily.6.6.157.1-1.azl3because thenet_shaperfamily was unavailable.Commits
2dc4cade1-[AI Generated] tools: add iproute2 netshaper support1ab8053b4-[AI Generated] sriov: verify VF netshaper bandwidth clampRecommended Validation
The image selections below are recommended targets, not claims that every image passed.
Key Test Cases:
verify_sriov_netshaper_bandwidth_clamp
Impacted LISA Features:
Sriov
Tested Azure Marketplace Images: