Bug#858003: Enabling autopkgtests for lvm2

Christian Ehrhardt christian.ehrhardt at canonical.com
Fri Mar 17 06:47:47 UTC 2017


Package: lvm2
Version: 2.02.168-1
Severity: normal

Subject: Enabling autpkgtests in lvm2.

Hi,
we recently ran into issues with lvm2 and kernel 4.10, see [1]..
Due to that I realized there were no dep8 tests for lvm2 yet.

The following is a series of commites as a suggestion that would add a few
basic checks.
That shall help to spot issues in LVM (or dependent packages) early on.

The suggested change tried to poke at the basics of LVM:
- pvcreate, pvmove, pvdisplay, pvck, pvscan
- vgcreate, vgremove, vgextend, vgreduce, vgck
- lvcreate, lvremove, snapshots, lvconvert

Surely there could be more, but then one always has to limit those tests to
have a reasonable execution time as well as to work in the autopkgtest
environment.
Since I use loop mounts as base disks I set isolation-machine and since I'd
need sudo on every other command it has needs-root.

I tested that using the Ubuntu Infrastructure building and testing LVM (as
in Debian + these tests) and passed on all archietctures that supported it
(e.g. those not able to provide isolation-machine just skip it).
Here is an example of such a tests [2] log.

Since it is just one script I saw no reason to post multiple commots
showing me to evolve that to work.
Therefore I'm just attaching the debdiff for latest Debian version.

Please do note, that the trigger for all of this was a crash on i386 [3] -
I just reported that on [1] so you can fix as well.
So if you apply the test today with a recent kernel it will crash on
vgremove, but it works fine as soon as the fix is applied.
Thereby I'd recommend you stage this change in your repo, but only upload
it together with the fix or the next lvm2 version bump.


Note: I also looked at enabling unit tests on build, but concluded it is
not worth it at the moment.
Mostly due to disfunctional tests:
- have fingerprint mismatches in some tests (is that a failure in lvm?)
- show memleak in valgrind tests (actual error?)
- Ruby processing doesn't mark errors as failure
- Ruby hard dep on 1.9
- Will need to be fixed upstream before they can be enabled.
I developed the fixes in git as well, but since I don't think it is worth
here a squashed diff FYI just in case you want to look at it as well [4].
There was an effort to revive them [5] , but I think it is incomplete at
the current version or I didn't check deep enough.


[1]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=858002
[2]: http://paste.ubuntu.com/24193814/
[3]:
https://sourceware.org/git/?p=lvm2.git;a=commit;h=46b735c937ce68e72d08997635321bf30240325d
[4]: http://paste.ubuntu.com/24175491/
[5]: https://www.redhat.com/archives/lvm-devel/2015-November/msg00165.html


-- 
Christian Ehrhardt
Software Engineer, Ubuntu Server
Canonical Ltd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-lvm-maintainers/attachments/20170317/7da97fee/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lvm2-autopkgtest.debdiff
Type: application/octet-stream
Size: 5707 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-lvm-maintainers/attachments/20170317/7da97fee/attachment-0001.obj>


More information about the pkg-lvm-maintainers mailing list