~raharper/curtin:fix/lvmroot-xfsboot-bump

Last commit made on 2019-12-18
Get this branch:
git clone -b fix/lvmroot-xfsboot-bump https://git.launchpad.net/~raharper/curtin
Only Ryan Harper can upload to this branch. If you are Ryan Harper please log in for upload directions.

Branch merges

Branch information

Name:
fix/lvmroot-xfsboot-bump
Repository:
lp:~raharper/curtin

Recent commits

4c59fc6... by Ryan Harper on 2019-12-18

Bump XFS /boot skip-by date out a while

78678e2... by Ryan Harper on 2019-12-17

vmtest: Fix a missing unset of OUTPUT_FSTAB

The initramfs-only-one branch modified how we use "dirty-disk" mode
which previously had unset environment variables used by curtin,
OUTPUT_FSTAB; this had some undesirable side-effects and instead
we set OUTPUT_FSTAB to a tmpdir and block-meta will now verify
expected environment variables. We missed a variant of the "dirty-disk"
mode used to recreate a specific bcache bug and now we see stack traces
warning about unset OUTPUT_FSTAB in vmtest output:

  raise KeyError("missing environment vars: %s" % missing)

This branch applies the same fix to this scenario.

b022ed4... by Ryan Harper on 2019-12-16

curthooks: handle s390x/aarch64 kernel install hooks

On s390x, and aarch64, the kernel package directly calls
arch specific commands (zipl, flash-kernel) which fail to run
correctly if an initramfs isn't already created in the image. This
broke installation when we attempt to only create the initramfs
once. This branch adds arch support into the code path to divert
not only 'update-initramfs' but the arch specific tools as well and
restores them prior to running the real 'update-initramfs' command.

LP: #1856038

e7952f6... by Ryan Harper on 2019-12-10

clear-holders: handle arbitrary order of devices to clear

At some point, the vmtest for LVM over bcache device list to clear
was sorted in a way that exposed a bug in the level calculation
resulting in not determining that the LVM device must be shutdown
before the bcache layer.

Resolve this by three changes: First we now sort the holders trees so
we have a consistent plan. Second when adding devices to the shutdown
registry, if the device has not been seen we take the max of either the
current level, or the size of the devices holders and lastly, the level
calculation requires recursion to find the full depth rather than just
taking the length of the holders list.

04adfd9... by Ryan Harper on 2019-12-04

curthooks: only run update-initramfs in target once

During an installation of Ubuntu; various packages (linux-image,
zfs-initramfs, mdadm, multipath-tools, etc) require an update
to the initramfs contents to ensure configuration details are
available. In the worst-case we call update-initramfs three
or more times. This branch disables update-initramfs in the
target system by moving it out of the way; then it replaces
the update-initramfs binary with equivalent of /bin/true as
some package's post-install hook call update-initramfs directly
and fail without it being present. At the end of curthooks
curtin re-enables the original update-initramfs and ensures
that all kernels installed will have an initrd.img created
or updated as needed.

Additional changes:
- block_meta
  - enable strict=True loading of command environment state
    to ensure curtin has required state present.
  - Replace open-coded file writing with util.write_files
    for mdadm and crypttab.
- curthooks
  - Use dpkg-divert to check if update-initramfs has been
    diverted.
  - Move update-initramfs actions (redhat & debian) under
    the same event reporter.
- vmtests
  - Don't unset OUTPUT_FSTAB, instead provide an alternative
    location.
  - Move class-based extra_kernel_args to the end; some
    class configs specify '---' which affects the
    carry-over kernel parameters used when booting the
    installed image.

LP: #1842264

3155c33... by Dan Watkins on 2019-12-04

test_network_mtu: bump fixby date for MTU tests

8c4b225... by Ryan Harper on 2019-11-22

block-discover: don't skip partitions on virtual devices

Curtin ignored virtual devices when processing blockdev data
on disks and partitions, however, some virtual devices may also
be partitioned (e.g. raid, bcache). This caused the storage
configuration to not include the base raid and partition elements
resulting in an invalid configuration.

LP: #1853018

c9112d4... by Ryan Harper on 2019-11-21

block-discover: handle partial probe data

The probe_data provided to curtin may only include a subset of
the types of data that curtin knows how to parse. Currently if
one of the types is not present in the probe_data, curtin raises
Exceptions which prevent callers from getting any storage config
from curtin. This branch allows curtin to handle missing data
and will log the errors but not raise Exceptions, leaving the
caller to handle and decide what to do with the storage config
produced.

LP: #1852351

95197ff... by Daniel Fox <email address hidden> on 2019-11-13

Fix parsing of squashfs: uri prefix for installation sources

util.santitize_source was truncating uris which used the squashfs:
prefix by taking the index of a character rather than a slice starting
at that character. This changes fixes this issue and provides the
intended behaviour and adds a deprecation warning to point to
the supported URI: "squashfs://".

LP: #1851271

48a476b... by Ryan Harper on 2019-11-05

Release 19.3

Bump the version in curtin/__init__.py to be 19.3.

LP: #1851390