Skip to content

Conversation

rickwu666666
Copy link
Contributor

@rickwu666666 rickwu666666 commented Oct 7, 2025

Add virtualization-kvm as part of requires of job virtualization/verify_lxd_vm

This can prevent the job execute on the system that not support KVM instead of execute the job and get fail in later stage

Description

Resolved issues

Documentation

Tests

Sideload result
The machine not support kvm
https://certification.canonical.com/hardware/202503-36377/submission/454484/test-results/

The machine support kvm
https://certification.canonical.com/hardware/202010-28347/submission/454489/test-results/

…fy_lxd_vm

This can prevent the job execute on the system that not support KVM instead of execute the job and get fail in later stage
@rickwu666666 rickwu666666 changed the title Add virtualization-kvm as part of requires of job verify_lxd_vm Add virtualization-kvm as part of requires of job verify_lxd_vm (New) Oct 7, 2025
Copy link

codecov bot commented Oct 7, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.77%. Comparing base (bd7332e) to head (1151cc8).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2143   +/-   ##
=======================================
  Coverage   52.77%   52.77%           
=======================================
  Files         395      395           
  Lines       42563    42563           
  Branches     7892     7892           
=======================================
  Hits        22461    22461           
  Misses      19302    19302           
  Partials      800      800           
Flag Coverage Δ
provider-base 29.33% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@bladernr
Copy link
Collaborator

bladernr commented Oct 7, 2025

This will remove a red flag for systems that do support KVM but it's disabled in BIOS. I have concern that simply skipping something that's expected to run and pass will lead to legitimate failures not being caught.

For example, when run on a system that supports virtualization:

$ kvm-ok
INFO: /dev/kvm exists
KVM acceleration can be used

and on the same system with virtualization "accidentally" disabled in BIOS:

$ kvm-ok
INFO: Your CPU does not support KVM extensions
INFO: For more detailed results, you should run this as root
HINT:   sudo /usr/sbin/kvm-ok

In the latter case, the test would simply be skipped saying "echo "kvm: unsupported" which is incorrect for the hardware...

Perhaps a better way would be to not skip this based on something easily changed by misconfiguration, and rather depend on a manifest entry somewhere in the virtualization chain that says "yes, we expect virtualization to be supported"

Additionally, has this been tested on architectures that are not x86 to be sure that the expected results carry over on things like arm64, Power, and s390?

@rickwu666666
Copy link
Contributor Author

This will remove a red flag for systems that do support KVM but it's disabled in BIOS. I have concern that simply skipping something that's expected to run and pass will lead to legitimate failures not being caught.

For example, when run on a system that supports virtualization:

$ kvm-ok
INFO: /dev/kvm exists
KVM acceleration can be used

and on the same system with virtualization "accidentally" disabled in BIOS:

$ kvm-ok
INFO: Your CPU does not support KVM extensions
INFO: For more detailed results, you should run this as root
HINT:   sudo /usr/sbin/kvm-ok

In the latter case, the test would simply be skipped saying "echo "kvm: unsupported" which is incorrect for the hardware...

Perhaps a better way would be to not skip this based on something easily changed by misconfiguration, and rather depend on a manifest entry somewhere in the virtualization chain that says "yes, we expect virtualization to be supported"

Additionally, has this been tested on architectures that are not x86 to be sure that the expected results carry over on things like arm64, Power, and s390?

You make the point. I'll think about how to resolve the situation that you mentioned.

@rickwu666666 rickwu666666 marked this pull request as draft October 9, 2025 03:05
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.

2 participants