Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add verify_supports_nvme #3122

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

kamalca
Copy link
Collaborator

@kamalca kamalca commented Dec 27, 2023

This test case checks whether the NVMe drivers are present such that the image can boot with DiskControllerType NVMe.

We needed a test that will do the same thing as nvme_enabled in the info section. This will enable AzQualify to check images before tagging them.
We cannot simply do verify_deployment_provision with disk_controller_type set to NVMe or use verify_nvme_disk_controller_type because deployment will fail if the image is not yet tagged as NVMe.

@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from 529ffbb to 3ec49f0 Compare December 28, 2023 18:52
@kamalca kamalca requested a review from squirrelsc January 2, 2024 17:16
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch 2 times, most recently from 162bd02 to f7fed9b Compare January 5, 2024 23:31
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from f7fed9b to d9c9396 Compare January 6, 2024 00:53
@kamalca kamalca marked this pull request as draft January 10, 2024 20:59
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from d9c9396 to e7b85e7 Compare April 23, 2024 22:03
@kamalca
Copy link
Collaborator Author

kamalca commented Apr 23, 2024

Rebased on PR #3255

@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch 3 times, most recently from 80a0bca to abbecf8 Compare April 29, 2024 16:40
)
image = node_runbook.image
# Failure conditions
if image and not isinstance(image, VhdSchema):
Copy link
Member

Choose a reason for hiding this comment

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

VHD should be able to set in the runbook to specify it supports nvme.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We can't rely on people manually specifying things in the runbook because it causes confusion. This means we need a good default value. If we don't include NVMe in VHD default, people will be confused why they can't deploy VHD with NVMe disk controller type. On the other hand, if default value has NVMe (as it currently does) then there will be confusing failures on this test case. The test case will assume VHD supports NVMe by default when this isn't necessarily true.
If someone wants to check if their VHD supports VHD all they have to do is confirm that this test case is pass and not skip. VHDs aren't tagged with any info so there shouldn't be an expectation that LISA will check if they are correctly tagged.

Copy link
Member

Choose a reason for hiding this comment

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

Can you list the situations in a table? With current logic, the test case is always disabled for vhd.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Marketplace SIG / CGI VHD
Has drivers PASS PASS PASS
Missing drivers, not tagged SKIP SKIP SKIP
Missing drivers, tagged capable FAIL FAIL VHD is never tagged

Copy link
Collaborator Author

@kamalca kamalca May 2, 2024

Choose a reason for hiding this comment

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

The main purpose of this test case is "Tag the image if and only if the test case passes" to be used before the image is published publicly to the marketplace. We don't really care about the skip vs. failure condition unless an image published in the marketplace is tagged but doesn't have drivers. This test case does not really care about VHDs because they aren't tagged.

Copy link
Member

@squirrelsc squirrelsc May 2, 2024

Choose a reason for hiding this comment

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

It maybe a case, that we need to verify a VHD is good with the tag before it's published. If the runbook is not modified, the vhd can be skipped to verify. It needs to be capable to verify vhd support that or not by adding tag in runbook. How about create unsupported NVMe capable for vhd by default?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Here is how I see the options

Deploying VHD on NVMe Running verify_support_nvme
Default support NVMe Works! Why is test case failing? :(
Default don't support NVMe Doesn't deploy :( Catches Failures

I could add a tag which it separate from disk_controller_type for the image, but it would be quite niche use case. It would be confusing and I don't think it would really be used.

Copy link
Member

Choose a reason for hiding this comment

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

If we add a test variable for the test case, can it solve the problem?

@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from abbecf8 to 5337e54 Compare May 1, 2024 19:28
@kamalca kamalca marked this pull request as ready for review May 2, 2024 18:07
@kamalca kamalca requested a review from johnsongeorge-w May 2, 2024 23:31
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from 5337e54 to c4c6608 Compare May 29, 2024 21:50
@kamalca kamalca closed this Jun 19, 2024
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from c4c6608 to c97b143 Compare June 19, 2024 17:30
@kamalca kamalca reopened this Jun 19, 2024
This test case checks whether the NVMe drivers are present such that the image can boot with DiskControllerType NVMe.
@kamalca kamalca force-pushed the kameroncarr/verify-nvme-boot branch from 187c3f3 to 02dab93 Compare October 22, 2024 22:45
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.

3 participants