~mwhudson/curtin:lp-1876626

Last commit made on 2020-05-04
Get this branch:
git clone -b lp-1876626 https://git.launchpad.net/~mwhudson/curtin
Only Michael Hudson-Doyle can upload to this branch. If you are Michael Hudson-Doyle please log in for upload directions.

Branch merges

Branch information

Name:
lp-1876626
Repository:
lp:~mwhudson/curtin

Recent commits

61a1166... by Michael Hudson-Doyle

block.detect_multipath: ignore fake "devices" from /proc/mounts

A tmpfs can be mounted with any old junk in the "device" field and
unfortunately casper sometimes puts "/dev/shm" there, which is usually a
directory. Ignore such cases. (See https://bugs.launchpad.net/bugs/1876626)

9b99e4b... by Ryan Harper

udev: use shlex.quote when shlex.split errors on shell-escape chars

The udev database may include shell escape characters in the output.
We want to avoid using shlex_quote unless needed as curtin does not
use the quoted value in our code and applying it to all of the values
breaks parsing of the udevadm info content.

If we encounter a ValueError while invoking shlex.split() then we
first use shlex_quote() and try parsing again and if that fails we
will try replacing shell-quote values with '_'. We log warning
whenever we have to quote or replace values.

- Python2.7 does not have shlex.quote, use pipes.quote (which was
  renamed to shlex.quote in Py3:
  https://docs.python.org/2/library/pipes.html#pipes.quote)
- Add unittest with original info dump from bug submitters system

LP: #1875085

f47a4c2... by Ryan Harper

lvm: don't use vgscan --mknodes

vgscan --mknodes has a bug which creates block device nodes for any
entry in dmsetup table if it doesn't exist yet. This breaks the
assumption that /dev/mapper entries are symlinks created by udev.
Until upstream RHBZ: #1828617 is resolved do not use --mknodes.

9d85462... by Ryan Harper

vmtest: rsync don't cross filesystem boundaries when copying

In some scenarios /var/lib/lxcfs is mounted with kernel bits
and rsync complains; instead we now copy using the --one-file-system
flag which avoids crossing these boundaries.

LP: #1873909

9943398... by Ryan Harper

vmtest: basic/basic_scsi adjust collect/tests for unstable device names

- For virtio-disks (TestBasic) use dname, except on centos66, use the byid
  serial name.
- For scsi-disks (TestScsiBasic) use wwn everywhere

LP: #1874100

07e9ed2... by Ryan Harper

Add unittests for partition_handler calc_[dm]_part_info and kpartx paths

ec598b0... by Ryan Harper

multipath: attempt to enforce /dev/mapper/mpath files are symlinks

Multipath device scanning and bring up variablity may result in
the creation of /dev/mapper/mpath* files that are block devices
instead of a symlink to the device mapper device (/dev/dm-0).

When these block files are present, this breaks assumptions in
curtin used to look up details in sysfs for a mapper device.

d39b9af... by Ryan Harper

block-meta: device mapper partitions may be block devices not links

In some cases the multipath library may create a block device which
is not a symbolic link to the device-mapper dev[1]. Curtin expects the
symlink. Remove the non-symlink file and allow kpartx to create it.

1. https://bugzilla.redhat.com/show_bug.cgi?id=869253

2f22690... by Ɓukasz Zemczak

Default to dm_name being id if empty earlier in dm_crypt_handler()

In other parts of the code, when deciding the path for dmcrypt_dev,
we default to 'id' when 'dm_name' is not defined. We ideally want
that to happen in all the cases. The defaulting has been there
already but a bit too late.

LP: #1874243

bcf890b... by Chad Smith

storage: correct declared schema draft version for storage schema

python3-jsonschema 3.2 (Ubuntu Focal) pays attention to the $schema
version declared in the provided schema when choosing validators.

Curtin now sets that appropriate schema draft version as 4 instead of
7 to give us better schema errors.