Conversation
…T-303971 Add new case for deleting external snapshot after reverting to an internal snapshot
XXX-304031 - Migrate a guest on non-canonical paths in shared_filesystems Signed-off-by: lcheng <lcheng@redhat.com>
There were already tests for negative test cases but we also want to confirm the valid values are passed to qemu correctly. Instead of creating another paramter variant similar to xattr, sandbox_mode create a variant on a higher level. Firstly, this allows more easily to define these tests for both externally and internally launched virtiofsd instances and secondly, in future commits the parameter coverage should be reorganized to allow for controlling the test matrix more easily and thus avoid matrix explosion. Furthermore, add a test case to check that virtiofsd's debug log level can be set correclty. Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
In time the matrix has grown considerably.
Restructure it to reduce number of variants and make it easier to select
tests.
1. Use external/internal to distinguish between tests where a running
virtiofsd instance is used or when libvirt starts it.
2. Where test scope seems independent or low risk, select certain test
cases only for
- 1 device
- 1 guest
- default settings (memoryBacking, parameter values)
namely:
a. lifecycle tests
b. libvirt qemu.conf tests
c. socket file check
d. command line checks for all parameters values
3. Tests that check the file system functionally use a combination of
settings, at this point we define 3:
i. to cover the case where no additional paramter is set
ii. to cover a reasonable setup for sharing a directory between two
guests with some security measures in place
iii. to cover values that weren't covered previously
Currently, all but the queue size parameter apply only to the launch
by libvirt. queue size itself is not a virtiofsd parameter, so cover
it only for in the single device for external set ref. 2. above.
4. Test matrix can be further reduced with low risk to:
- only 1 coldplug_unplug case per memory backing and launch mode
becaues nop and hotplug cover the other scenarios more exhaustively
- retry_two_devices should be independent from chosen memory backing
and doesn't apply to hotplug
- parameter sets are only really relevant for internally launched
instances because only queue size applies to both modes
- not all unplug scenarios have to use the alias for unplugging,
most don't have to
5. Some other changes were necessary to match the new matrix.
- Enable with_alias detach test case for externally launched
instance: checking for the log file is only valid for internally
launched instances.
- Don't run lifecycle tests with extenrally launched instance if
it means the VM is stopped as in this case the virtiofsd exits.
6. Finally, fix also some script issues that surfaced during test run of
the new matrix.
Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
Sometimes md5sum gets stuck. This might happen because there's a problem with the file. In each guest sync the mounted folder before creating the md5sum to make sure the cache and storage are synchronized. Also, move the filename definition out because it was only defined once in the first loop giving the wrong impression that it would vary. However, we always write only one file so it's reasonable to have a single file name. Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
Agreed to rename tests and move into their own folder because: 1. virtiofs is one example of <filesystem>, historically there were others, too. 2. virtiofs for us has now its own high level test plan, so according to our internal strategy it should be easier to find. Additionally, make the `unprivileged` test variants a subvariant of `virtiofs`. This way with `virtiofs` all test cases are selected. Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
Managedsave for internally launched had an issue before 10.0.0 Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
…th-CPU-feature Add case to disable pauth cpu feature
The patch introduces guest kernel debugging via kdump mechanism.
The script is used to test the kdump functionality of the guest(s).
1. Check if kdump.service is operational
2. Get the vmcores present in the guest
3. Load the stress app if specified
4. Trigger crash simultaneously in all guests
5. Debug vmcore using crash utility if specified
Using this patch the followng scenarios can be verified
1. single-guest:
a. kdump with no stress
b. kdump with stress
c. kdump with stress with crash utility
2. multi-guests:
a. kdump with no stress
b. kdump with stress
c. kdump with stress with crash utility
Signed-off-by: Misbah Anjum N <misanjum@linux.vnet.ibm.com>
This Patch adds support for testing Crash Utility
for vmcore generated by "virsh dump" command.
Crash Utility is a tool that allows us to interactively
analyze a running Linux system as well as a core dump created.
This crash_utility function works as following:
Returns:
0: Success
1: Crash command failed
2: Dependency installation failed or vmlinux not found
3: Kernel mismatch between host and guest
4: Guest kernel retrieval failed
5: Unsupported distribution
6: virsh dump unsuccessful
Signed-off-by: Misbah Anjum N <misanjum@linux.vnet.ibm.com>
Automate case: VIRT-302169 - [virtual disks] [SCSI]Start vm with block lun disk(scsi-block) and rawio attribute Signed-off-by: meinaLi <meili@redhat.com>
As dmidecode is not available in ppc64 , removing it and replacing it with lshw as lshw is a standard way to get the resources details on ppc64 arch Keeping dmidecide for other arch Signed-off-by: Tasmiya Nalatwad <tasmiya@linux.vnet.ibm.com>
fix cpu max value increases
Signed-off-by: Fangge Jin <fjin@redhat.com>
Add test cases for live updating iothread_vq_mapping
There have been changes in the kernel so that now, sometimes a device would show up, other times it wouldn't. The test case was motivated by a critical issue where removing all channel paths led to an unusable system. Let's reduce our test condition to that. Signed-off-by: Sebastian Mitterle <smitterl@redhat.com>
various_numa_topology_settings: fix var check
numa_config_with_auto_placement: fix iothreadinfo check
filesystem_device: expand test coverage and rename
fix domstats failures by adding "echo 1 > /proc/sys/kernel/sched_schedstats" before domststs command Signed-off-by: zhentang-tz <zhetang@redhat.com>
Resolved script failures caused by recent changes in usbredirection command syntax. Rewritted method "start_usbredirserver" to maintain compatibility with both new and old usbredir command formats. Signed-off-by: zhentang-tz <zhetang@redhat.com>
migration: Add case about shared_filesystems
…_with_new_hyperv_enlightments cpu: add case for starting guest with new hyperv enlightments
…sh_cpu_model_with_qemu cpu: add case for virsh cpu models compare with qemu
Add new case VIRT-299042 Life cycle for various config of dimm memory device Signed-off-by: liang-cong-red-hat <lcong@redhat.com>
Add vhostuser support for passt in sevaral scenarios. Signed-off-by: Yalan Zhang <yalzhang@redhat.com>
…7-skipped-tests resolving skipped cases: 56145
Signed-off-by: Dan Zheng <dzheng@redhat.com>
…autotest#6418) Device's <seclabel relabel='yes'/> with no <label/> will be rejected. So updating the case. Signed-off-by: Yingshun Cui <yicui@redhat.com>
migration_numa: add case
virsh_guestinfo: add case for cpu load
…esc_cmd add case for virsh net-desc cmd
…etadata_cmd_display_and_modification add case for virsh net-metadata cmd
…st#6422) From libvirt v10.6.0[1], libvirt forbids changing the portgroup of interface device. [1]: https://gitlab.com/libvirt/libvirt/-/commit/c3302ceb1d Signed-off-by: Han Han <hhan@redhat.com>
Failed to run virtiofsd/swtpm command on target host which lead to 'Permission denied' error. So update case. Signed-off-by: lcheng <lcheng@redhat.com>
Fix below error: "value value is not any of [<class 'list'>], it is a <class 'str'>" Signed-off-by: liang-cong-red-hat <lcong@redhat.com>
This test script checks for any AVC denials during test execution. However, it doesn't clear the audit log history before running, which causes the test to always fail. The script has been updated to check timestamps and only report a failure if AVC denials occur within the test start and end time window. Signed-off-by: Yalan Zhang <yalzhang@redhat.com>
Add new test case: guest_kdump test
virsh-snapshot: Update logic to verify snapshot creation
libvirt-mem: Enable check for test_qemu_cmd
virsh-dump: Add Crash Utility Tests for vmcore
There is AVC denials in the audit log with privious code. After updating the lable of the *.fifo file, the issue can be fixed. Signed-off-by: Yalan Zhang <yalzhang@redhat.com>
In the script, it creates a new directory /var/tmp, and put the saved file into this directory. It causes avc denials log in the audit log since this directory is not configured with proper selinux lables, fix it. Signed-off-by: Yalan Zhang <yalzhang@redhat.com>
update_device: Add the missing source network
…x_type_mismatch_error Fix type mismatch error
migration: Fix connect sock issue
According to https://gitlab.com/libvirt/libvirt/-/commit/312088d9b62334c950310f369b2e0fe2302a74a3 the command will return an empty string instead of error message after libvirt-11.3.0 Signed-off-by: Dan Zheng <dzheng@redhat.com>
virsh_metadata: fix no option
Signed-off-by: Dan Zheng <dzheng@redhat.com>
migration_postcopy_bandwidth: fix bandwidth
…gration_params Revert "migration_postcopy_bandwidth: fix bandwidth"
Automate case for print blkhash of converted image in virt-v2v debugging output Signed-off-by: Ganesh Hubale <ghubale@redhat.com>
…t_blkhash Add a case to test nbdcopy with blkhash in virt-v2v debugging output
Signed-off-by: Xiaodai Wang <xiaodwan@redhat.com>
There was a problem hiding this comment.
Summary of Changes
Hello @xiaodwan, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request is a test branch that introduces a substantial number of new configuration files and updates existing ones across various libvirt test suites. The changes aim to expand test coverage for features like backing chain operations, BIOS configurations, controller functionalities, CPU features (especially for AArch64 SVE and GIC), daemon management, event handling, GPU support on AArch64, guest agent behaviors, kernel debugging, memory management (including hotplug, hugepages, ballooning, and various memory device types), migration scenarios (including async operations, copy storage, NUMA, and vTPM), NUMA topology, PCI passthrough, save/restore operations, SCSI device handling, security features like RNG, and extensive SR-IOV and vIOMMU functionalities. The updates also include refactoring existing tests for better clarity and adding new negative test cases.
Highlights
- Documentation Update: Updated the link to the PR Review and Contribute Practices document to point to the new Guidelines.rst file.
- Libvirt Test Configuration: Added new parameters for NFS setup and updated disk definitions in blockcommit tests.
- Storage Configuration: Introduced a new RBD with LUKS and authentication variant in blockcopy tests.
- PCI Controller Testing: Added a new test for PCI controller memory reservation.
- AArch64 CPU Feature Testing: Refactored SVE (Scalable Vector Extension) vector length tests and added new variants for optimized routines and selftests on AArch64.
- AArch64 Interrupt Controller Testing: Added new tests for AArch64 GIC (Generic Interrupt Controller) versions.
- VM Scalability Testing: Introduced a new test for multiple VMs running under stress.
- Hyper-V Feature Support: Added new Hyper-V features (tlbflush_direct_extended, emsr_bitmap, xmm_input, passthrough) to VM feature tests.
- Libvirt Daemon Management: Added new tests for checking libvirt daemon socket files, users, and virsh connection switching between monolithic and modular daemons.
- Virtlogd Configuration: Expanded virtlogd configuration tests with numerous new scenarios for specific config files, crash logs, and client management.
- AArch64 GPU Testing: Added new tests for GPU-related functionalities on AArch64, including hotplug, lifecycle, CUDA sanity, MIG sanity, and NVIDIA driver checks.
- Guest OS Boot Order: Introduced new tests for booting from USB, virtiofs, and multiple boot devices/orders.
- Guest OS Firmware Configuration: Added new tests for SMBIOS mode and sysinfo fwcfg configuration in guest OS booting.
- Memory Device Management: Introduced various new memory device tests, including DIMM, NVDIMM, and virtio-mem, covering hotplug/unplug, access/discard modes, and NUMA allocation.
- Memory Ballooning: Added new tests for memory ballooning, including freepage reporting and period configuration.
- Secure Dump: Introduced tests for secure dump on s390-virtio.
- Migration Robustness: Added new tests for aborting migration jobs, destroying VMs during migration phases, and migrating VMs with specific CPU modes or host UUIDs.
- P2P Migration Keepalive: Introduced tests for P2P keepalive customization and default behavior during migration.
- Copy Storage Migration: Added new tests for copy storage migration, covering aborting jobs, querying info, autoskipped disks, disk IO load, various disk types, bandwidth limits, sparsity retention, and vhost-vdpa.
- NUMA Configuration: Introduced tests for NUMA tuning migration and various host/guest NUMA configurations.
- PCI Passthrough Robustness: Added new tests for PCI passthrough robustness, including various device operations and VM lifecycle interactions.
- SCSI Device Management: Introduced new tests for SCSI command execution with hostdev and SCSI controller driver plug/unplug.
- SR-IOV and IOMMU Testing: Added new tests for SR-IOV capabilities, network connections, nodedev operations, and plug/unplug scenarios, including VFIO variant drivers and IOMMU settings.
- IOMMU Device Testing: Introduced tests for various IOMMU models (virtio, intel, smmuv3) covering device lifecycle, repeated resets, network performance, and file transfer.
- Snapshot Management: Added new tests for snapshot operations, including deleting disk/memory snapshots, reverting external/internal snapshots, and handling snapshots after XML updates.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments or fill out our survey to provide feedback.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Code Review
This pull request introduces a substantial number of new test configurations and refactors existing ones, primarily to extend test coverage across different architectures and scenarios. The changes are extensive, touching upon various features like memory management, migration, NUMA, and device passthrough. While the majority of the changes appear to be correct extensions of the test suite, I've identified several typos in variable and variant names, along with a critical syntax error in one of the new configuration files that would cause a test to fail.
| ssh_timeout = 60 | ||
| start_vm = "yes" | ||
| # Local URI | ||
| virsh_migrate_connect_uri = qemu:///system" |
| virtlogd_config_bak_file = "/etc/sysconfig/virtlogd.bak" | ||
| virtlogd_config_file_new = "/etc/libvirt/virtlogd-new.conf" | ||
| start_vm = no | ||
| - record_qenu_crash_log: |
| func_supported_since_libvirt_ver = (9, 4, 0) | ||
| need_start_vm = "yes" | ||
| thread_pool_min = 2147483647 | ||
| thread-pool-max = 2147483647 |
| cmd_options = '--config' | ||
| iothread_config = {'iothread': [{'id': '2', 'thread_pool_min': '1', 'thread_pool_max': '1', 'poll': {'max': '1', 'grow': '1', 'shrink': '1'}}]} | ||
| test_operations = "iothreadset" | ||
| check_iotheadids_inactive = "yes" |
| - vcpupin_current_inactive_vm: | ||
| vcpupin_conf = "{'0': 'x,y', '1': 'x-y,^z', '2': 'x-y,^z,m', '3': 'r'}" | ||
| affinity_pattern = 'CPU Affinity:\s*(.*) .*out of' | ||
| - cpuset_limilted_in_cgroup: |
| type = vm_cuda_sanity | ||
| start_vm = "no" | ||
| cuda_samples_path = "http://download.libvirt.redhat.com/libvirt-CI-resources/gpu/cuda-samples.tar.gz" | ||
| cuda_tests = ["./cuda-samples/build/Samples/1_Utilities/deviceQuery/deviceQuery", "./cuda-samples/build/Samples/1_Utilities/bandwidthTest/bandwidthTest", "./cuda-samples/build/Samples//0_Introduction/simpleMultiCopy/simpleMultiCopy"] |
There was a problem hiding this comment.
There is a double slash // in the path for simpleMultiCopy. This might be a typo.
cuda_tests = ["./cuda-samples/build/Samples/1_Utilities/deviceQuery/deviceQuery", "./cuda-samples/build/Samples/1_Utilities/bandwidthTest/bandwidthTest", "./cuda-samples/build/Samples/0_Introduction/simpleMultiCopy/simpleMultiCopy"]
| status_error = "yes" | ||
| - multi_disks_bootable: | ||
| download_disk1_img = yes | ||
| disk1_img_url = |
| check_prompt = "UEFI .* USB|1. USB MSC Drive .*|UsbBootDetectMedia: UsbBootIsUnitReady .*|.*UsbBootExecCmd: Success to Exec 0x0 Cmd \(Result = 1\).*" | ||
| only q35, aarch64 | ||
| aarch64: | ||
| bootmenu_dict = {'bootmenu_enable': 'yes', 'bootmenu_timeout': '3000'} |
| err_msg = "target scsi:${same_index} already exists" | ||
| - hotplug_same_address: | ||
| only two_contrs | ||
| same_address = { "domain": '0x0000', 'funtion': '0x0', 'bus': '0x08', 'slot': '0x00'} |
| kernel_download_cmd = "cd /var/tmp && brew download-build --rpm %s && rpm2cpio %s | cpio -idm" | ||
| kernel_tar_cmd = "cd /var/tmp && tar Jxf %s --strip-components 1 -C ${target_dir}" | ||
| kernel_selftest_compile_cmd = "cd ${kernel_testing_dir}; make all -C selftests/ TARGETS=arm64" | ||
| sve_stress_get_lenths = "${suite_dir}/sve-probe-vls" |
No description provided.