Re: [PATCH 07/13] tests/avocado/kvm_xen_guest.py: cope with asset RW requirements

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



David Woodhouse <dwmw2@xxxxxxxxxxxxx> writes:

> On Mon, 2024-07-29 at 11:58 +0100, Daniel P. Berrangé wrote:
>> On Fri, Jul 26, 2024 at 09:44:32AM -0400, Cleber Rosa wrote:
>> > Some of these tests actually require the root filesystem image,
>> > obtained through Avocado's asset feature and kept in a common cache
>> > location, to be writable.
>
> Hm, I'm not sure *why* they require a writable image. Mostly they're
> just testing the interrupt routing. What's the failure mode for a read-
> only image?

There are no real failures with readonly=on although you do see init
complain a bit about not being able to mount /dev and open log files.
snapshot allows that to happen but doesn't change the underlying
storage.

>
>> > @@ -56,11 +57,19 @@ def common_vm_setup(self):
>> >                                            "367962983d0d32109998a70b45dcee4672d0b045")
>> >          self.rootfs = self.get_asset("rootfs.ext4",
>> >                                       "f1478401ea4b3fa2ea196396be44315bab2bb5e4")
>> > +        if readwrite:
>> > +            dest = os.path.join(self.workdir, os.path.basename(self.rootfs))
>> > +            shutil.copy(self.rootfs, dest)
>> > +            self.rootfs = dest
>> 
>> This is a very expensive way of creating a writable disk. Better to
>> avoid adding this 'readwrite' parameter at all, and instead create
>> a throwaway qcow2 overlay for the image for all tests. That ensures
>> writability for everything in a cheap manner.
>
> Or just use -snapshot?

-- 
Alex Bennée
Virtualisation Tech Lead @ Linaro





[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux