Skip to content

Fix km_ebpfcore_restart_test to run inside VM#5000

Merged
Alan-Jowett merged 1 commit intomicrosoft:mainfrom
Alan-Jowett:fix/km-ebpfcore-restart-test-vm-routing
Feb 20, 2026
Merged

Fix km_ebpfcore_restart_test to run inside VM#5000
Alan-Jowett merged 1 commit intomicrosoft:mainfrom
Alan-Jowett:fix/km-ebpfcore-restart-test-vm-routing

Conversation

@Alan-Jowett
Copy link
Copy Markdown
Member

Problem

The km_ebpfcore_restart_test has been failing every scheduled run since it was introduced (issue #4950). The previous RCA (Chocolatey missing) was fixed by PR #4968, but the test continues to fail with a new error:

Failed to create map, error: -1 Failed to open ebpfcore service, error: 1060 FAIL: ebpfcore service does not exist - environment issue!

Root Cause

The test command .\ebpf_restart_test_controller.exe was invoked directly on the 1ES runner host, but the eBPF components (ebpfcore service) are installed inside the Hyper-V VM (runner_vm) by setup_ebpf_cicd_tests.ps1. Error 1060 is ERROR_SERVICE_DOES_NOT_EXIST.

Other KM tests (e.g., km_mt_stress_tests_restart_extension) correctly route execution through execute_ebpf_cicd_tests.ps1, which uses Invoke-OnHostOrVM to run inside the VM.

Fix

Route the restart test through the existing VM execution infrastructure:

  1. cicd.yml - Changed test_command to use execute_ebpf_cicd_tests.ps1 with RestartEbpfCore option
  2. run_driver_tests.psm1 - Added RestartEbpfCore parameter to Invoke-CICDStressTests
  3. vm_run_tests.psm1 - Passes the new option through

Fixes #4950

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes the km_ebpfcore_restart_test CI job by routing execution through the existing VM-based test execution path, ensuring the restart controller runs inside the Hyper-V VM where ebpfcore is installed.

Changes:

  • Update the km_ebpfcore_restart_test workflow command to call execute_ebpf_cicd_tests.ps1 with a new stress-test option (RestartEbpfCore).
  • Add a RestartEbpfCore switch to Invoke-CICDStressTests to run ebpf_restart_test_controller.exe via the standard VM test harness.
  • Plumb the new option through vm_run_tests.psm1 option parsing and into Invoke-CICDStressTests.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
.github/workflows/cicd.yml Runs the restart test through execute_ebpf_cicd_tests.ps1 so it executes inside the VM.
scripts/vm_run_tests.psm1 Recognizes RestartEbpfCore in -Options and forwards it to stress test invocation.
scripts/run_driver_tests.psm1 Implements RestartEbpfCore handling in Invoke-CICDStressTests to execute the restart controller.

@Alan-Jowett Alan-Jowett self-assigned this Feb 11, 2026
@Alan-Jowett Alan-Jowett added this to the 2602 milestone Feb 11, 2026
@Alan-Jowett Alan-Jowett force-pushed the fix/km-ebpfcore-restart-test-vm-routing branch from c5538ff to dc92354 Compare February 13, 2026 16:41
@Alan-Jowett Alan-Jowett force-pushed the fix/km-ebpfcore-restart-test-vm-routing branch from dc92354 to c47fc76 Compare February 17, 2026 17:08
The restart test controller was invoked directly on the 1ES runner host,
but ebpfcore is installed inside the Hyper-V VM. This caused error 1060
(ERROR_SERVICE_DOES_NOT_EXIST) since the service doesn't exist on the host.

Route the test through execute_ebpf_cicd_tests.ps1 with a new
RestartEbpfCore stress test option, matching the pattern used by
km_mt_stress_tests_restart_extension.

Fixes microsoft#4950
@Alan-Jowett Alan-Jowett force-pushed the fix/km-ebpfcore-restart-test-vm-routing branch from c47fc76 to efe3d20 Compare February 18, 2026 17:23
@Alan-Jowett Alan-Jowett added this pull request to the merge queue Feb 20, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Feb 20, 2026
@Alan-Jowett Alan-Jowett added this pull request to the merge queue Feb 20, 2026
Merged via the queue into microsoft:main with commit 228789c Feb 20, 2026
114 checks passed
@Alan-Jowett Alan-Jowett deleted the fix/km-ebpfcore-restart-test-vm-routing branch February 20, 2026 19:42
@github-project-automation github-project-automation Bot moved this from Todo to Done in eBPF for Windows Triage Feb 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

Workflow failed - km_ebpfcore_restart_test

4 participants