Mount by UUID in fstab of multipath devices on non-root mountpoints impacts reliability of installed system
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
curtin |
Fix Committed
|
High
|
Ryan Harper |
Bug Description
curtin currently constructs fstab entries for multipath devices in the target system using UUID as the reference to mount by. The filesystem UUID is by definition not a unique identifier for a device in multipath, since udev will show at least three devices with this UUID: minimum of 2 members, and the mpath device exposed via devmapper.
This is not a problem for the root filesystem, because in actuality /etc/fstab is never used for mounting the rootfs; the rootfs is mounted by the kernel commandline + the initrd, and the root value that curtin injects into the bootloader config (grub) for the kernel commandline uses the correct form instead.
However, if a user partitions a multipath-backed disk into multiple filesystems and mounts some of these at non-root locations, the mount of these devices will be racy and there is risk that an underlying device will be mounted instead of the intended multipath device. This means that the system will be adversely affected by storage path failures when by design it should not be.
Related branches
- Server Team CI bot: Needs Fixing (continuous-integration)
- Dan Watkins (community): Approve
-
Diff: 16912 lines (+12842/-697)95 files modifiedHACKING.rst (+3/-4)
Makefile (+5/-1)
curtin/__init__.py (+1/-1)
curtin/block/__init__.py (+50/-6)
curtin/block/clear_holders.py (+88/-21)
curtin/block/deps.py (+1/-1)
curtin/block/multipath.py (+74/-2)
curtin/block/schemas.py (+8/-2)
curtin/block/zfs.py (+24/-0)
curtin/commands/block_meta.py (+138/-55)
curtin/commands/curthooks.py (+229/-53)
curtin/commands/install.py (+5/-1)
curtin/deps/__init__.py (+1/-1)
curtin/distro.py (+25/-2)
curtin/net/deps.py (+3/-3)
curtin/storage_config.py (+108/-22)
curtin/udev.py (+15/-7)
curtin/util.py (+23/-8)
debian/changelog (+81/-0)
debian/control (+1/-1)
doc/topics/config.rst (+6/-1)
doc/topics/integration-testing.rst (+13/-6)
doc/topics/storage.rst (+17/-2)
examples/tests/basic-dasd.yaml (+2/-2)
examples/tests/bcache-ceph-nvme-simple.yaml (+107/-0)
examples/tests/bcache-wipe-xfs.yaml (+4/-3)
examples/tests/bridging_network_v2.yaml (+38/-0)
examples/tests/dirty_disks_config.yaml (+9/-1)
examples/tests/network_mtu_networkd.yaml (+93/-0)
examples/tests/reuse-raid-member-partition.yaml (+73/-0)
examples/tests/reuse-raid-member-wipe.yaml (+71/-0)
helpers/common (+84/-13)
tests/data/probert_storage_multipath.json (+1059/-0)
tests/data/probert_storage_raid1_partitions.json (+951/-0)
tests/data/probert_storage_zlp6.json (+6980/-0)
tests/unittests/test_block.py (+59/-0)
tests/unittests/test_block_dasd.py (+1/-1)
tests/unittests/test_block_multipath.py (+87/-6)
tests/unittests/test_block_zfs.py (+26/-0)
tests/unittests/test_clear_holders.py (+131/-11)
tests/unittests/test_commands_block_meta.py (+550/-35)
tests/unittests/test_commands_collect_logs.py (+3/-1)
tests/unittests/test_curthooks.py (+338/-31)
tests/unittests/test_distro.py (+71/-0)
tests/unittests/test_storage_config.py (+152/-10)
tests/unittests/test_udev.py (+15/-14)
tests/unittests/test_util.py (+120/-1)
tests/vmtests/__init__.py (+244/-34)
tests/vmtests/helpers.py (+11/-6)
tests/vmtests/image_sync.py (+10/-3)
tests/vmtests/releases.py (+34/-0)
tests/vmtests/test_apt_config_cmd.py (+1/-8)
tests/vmtests/test_basic.py (+69/-89)
tests/vmtests/test_basic_dasd.py (+7/-16)
tests/vmtests/test_bcache_basic.py (+4/-3)
tests/vmtests/test_bcache_bug1718699.py (+4/-3)
tests/vmtests/test_bcache_ceph.py (+30/-3)
tests/vmtests/test_bcache_partitions.py (+4/-3)
tests/vmtests/test_fs_battery.py (+4/-3)
tests/vmtests/test_iscsi.py (+5/-3)
tests/vmtests/test_journald_reporter.py (+4/-7)
tests/vmtests/test_lvm.py (+14/-21)
tests/vmtests/test_lvm_iscsi.py (+4/-3)
tests/vmtests/test_lvm_raid.py (+3/-3)
tests/vmtests/test_lvm_root.py (+16/-1)
tests/vmtests/test_mdadm_bcache.py (+86/-40)
tests/vmtests/test_mdadm_iscsi.py (+4/-3)
tests/vmtests/test_multipath.py (+5/-5)
tests/vmtests/test_network.py (+3/-3)
tests/vmtests/test_network_alias.py (+4/-3)
tests/vmtests/test_network_bonding.py (+3/-3)
tests/vmtests/test_network_bridging.py (+22/-3)
tests/vmtests/test_network_ipv6.py (+0/-4)
tests/vmtests/test_network_ipv6_static.py (+3/-3)
tests/vmtests/test_network_ipv6_vlan.py (+7/-3)
tests/vmtests/test_network_mtu.py (+41/-13)
tests/vmtests/test_network_static.py (+3/-3)
tests/vmtests/test_network_static_routes.py (+5/-5)
tests/vmtests/test_network_vlan.py (+11/-3)
tests/vmtests/test_nvme.py (+4/-7)
tests/vmtests/test_old_apt_features.py (+3/-2)
tests/vmtests/test_pollinate_useragent.py (+4/-3)
tests/vmtests/test_preserve.py (+4/-3)
tests/vmtests/test_preserve_raid.py (+4/-3)
tests/vmtests/test_raid5_bcache.py (+4/-3)
tests/vmtests/test_reuse_raid_member.py (+63/-0)
tests/vmtests/test_simple.py (+10/-10)
tests/vmtests/test_uefi_basic.py (+8/-7)
tests/vmtests/test_zfsroot.py (+20/-8)
tools/block-discover-to-config (+3/-1)
tools/jenkins-runner (+50/-0)
tools/launch (+10/-0)
tools/vmtest-filter (+12/-1)
tools/vmtest-sync-images (+15/-13)
tools/xkvm (+20/-4)
- Server Team CI bot: Needs Fixing (continuous-integration)
- Dan Watkins (community): Approve
-
Diff: 16912 lines (+12842/-697)95 files modifiedHACKING.rst (+3/-4)
Makefile (+5/-1)
curtin/__init__.py (+1/-1)
curtin/block/__init__.py (+50/-6)
curtin/block/clear_holders.py (+88/-21)
curtin/block/deps.py (+1/-1)
curtin/block/multipath.py (+74/-2)
curtin/block/schemas.py (+8/-2)
curtin/block/zfs.py (+24/-0)
curtin/commands/block_meta.py (+138/-55)
curtin/commands/curthooks.py (+229/-53)
curtin/commands/install.py (+5/-1)
curtin/deps/__init__.py (+1/-1)
curtin/distro.py (+25/-2)
curtin/net/deps.py (+3/-3)
curtin/storage_config.py (+108/-22)
curtin/udev.py (+15/-7)
curtin/util.py (+23/-8)
debian/changelog (+81/-0)
debian/control (+1/-1)
doc/topics/config.rst (+6/-1)
doc/topics/integration-testing.rst (+13/-6)
doc/topics/storage.rst (+17/-2)
examples/tests/basic-dasd.yaml (+2/-2)
examples/tests/bcache-ceph-nvme-simple.yaml (+107/-0)
examples/tests/bcache-wipe-xfs.yaml (+4/-3)
examples/tests/bridging_network_v2.yaml (+38/-0)
examples/tests/dirty_disks_config.yaml (+9/-1)
examples/tests/network_mtu_networkd.yaml (+93/-0)
examples/tests/reuse-raid-member-partition.yaml (+73/-0)
examples/tests/reuse-raid-member-wipe.yaml (+71/-0)
helpers/common (+84/-13)
tests/data/probert_storage_multipath.json (+1059/-0)
tests/data/probert_storage_raid1_partitions.json (+951/-0)
tests/data/probert_storage_zlp6.json (+6980/-0)
tests/unittests/test_block.py (+59/-0)
tests/unittests/test_block_dasd.py (+1/-1)
tests/unittests/test_block_multipath.py (+87/-6)
tests/unittests/test_block_zfs.py (+26/-0)
tests/unittests/test_clear_holders.py (+131/-11)
tests/unittests/test_commands_block_meta.py (+550/-35)
tests/unittests/test_commands_collect_logs.py (+3/-1)
tests/unittests/test_curthooks.py (+338/-31)
tests/unittests/test_distro.py (+71/-0)
tests/unittests/test_storage_config.py (+152/-10)
tests/unittests/test_udev.py (+15/-14)
tests/unittests/test_util.py (+120/-1)
tests/vmtests/__init__.py (+244/-34)
tests/vmtests/helpers.py (+11/-6)
tests/vmtests/image_sync.py (+10/-3)
tests/vmtests/releases.py (+34/-0)
tests/vmtests/test_apt_config_cmd.py (+1/-8)
tests/vmtests/test_basic.py (+69/-89)
tests/vmtests/test_basic_dasd.py (+7/-16)
tests/vmtests/test_bcache_basic.py (+4/-3)
tests/vmtests/test_bcache_bug1718699.py (+4/-3)
tests/vmtests/test_bcache_ceph.py (+30/-3)
tests/vmtests/test_bcache_partitions.py (+4/-3)
tests/vmtests/test_fs_battery.py (+4/-3)
tests/vmtests/test_iscsi.py (+5/-3)
tests/vmtests/test_journald_reporter.py (+4/-7)
tests/vmtests/test_lvm.py (+14/-21)
tests/vmtests/test_lvm_iscsi.py (+4/-3)
tests/vmtests/test_lvm_raid.py (+3/-3)
tests/vmtests/test_lvm_root.py (+16/-1)
tests/vmtests/test_mdadm_bcache.py (+86/-40)
tests/vmtests/test_mdadm_iscsi.py (+4/-3)
tests/vmtests/test_multipath.py (+5/-5)
tests/vmtests/test_network.py (+3/-3)
tests/vmtests/test_network_alias.py (+4/-3)
tests/vmtests/test_network_bonding.py (+3/-3)
tests/vmtests/test_network_bridging.py (+22/-3)
tests/vmtests/test_network_ipv6.py (+0/-4)
tests/vmtests/test_network_ipv6_static.py (+3/-3)
tests/vmtests/test_network_ipv6_vlan.py (+7/-3)
tests/vmtests/test_network_mtu.py (+41/-13)
tests/vmtests/test_network_static.py (+3/-3)
tests/vmtests/test_network_static_routes.py (+5/-5)
tests/vmtests/test_network_vlan.py (+11/-3)
tests/vmtests/test_nvme.py (+4/-7)
tests/vmtests/test_old_apt_features.py (+3/-2)
tests/vmtests/test_pollinate_useragent.py (+4/-3)
tests/vmtests/test_preserve.py (+4/-3)
tests/vmtests/test_preserve_raid.py (+4/-3)
tests/vmtests/test_raid5_bcache.py (+4/-3)
tests/vmtests/test_reuse_raid_member.py (+63/-0)
tests/vmtests/test_simple.py (+10/-10)
tests/vmtests/test_uefi_basic.py (+8/-7)
tests/vmtests/test_zfsroot.py (+20/-8)
tools/block-discover-to-config (+3/-1)
tools/jenkins-runner (+50/-0)
tools/launch (+10/-0)
tools/vmtest-filter (+12/-1)
tools/vmtest-sync-images (+15/-13)
tools/xkvm (+20/-4)
- Server Team CI bot: Needs Fixing (continuous-integration)
- Dan Watkins (community): Approve
-
Diff: 15603 lines (+12330/-488)87 files modifiedHACKING.rst (+3/-4)
curtin/__init__.py (+1/-1)
curtin/block/clear_holders.py (+88/-21)
curtin/block/multipath.py (+74/-2)
curtin/block/schemas.py (+7/-1)
curtin/block/zfs.py (+24/-0)
curtin/commands/block_meta.py (+99/-46)
curtin/commands/curthooks.py (+200/-53)
curtin/commands/install.py (+5/-1)
curtin/distro.py (+25/-2)
curtin/net/deps.py (+3/-3)
curtin/storage_config.py (+105/-20)
curtin/udev.py (+15/-7)
curtin/util.py (+12/-5)
debian/changelog (+63/-0)
debian/control (+1/-1)
doc/topics/config.rst (+6/-1)
doc/topics/storage.rst (+17/-2)
examples/tests/basic-dasd.yaml (+2/-2)
examples/tests/bcache-ceph-nvme-simple.yaml (+107/-0)
examples/tests/bcache-wipe-xfs.yaml (+4/-3)
examples/tests/bridging_network_v2.yaml (+38/-0)
examples/tests/dirty_disks_config.yaml (+9/-1)
examples/tests/network_mtu_networkd.yaml (+93/-0)
examples/tests/reuse-raid-member-partition.yaml (+73/-0)
examples/tests/reuse-raid-member-wipe.yaml (+71/-0)
helpers/common (+84/-13)
tests/data/probert_storage_multipath.json (+1059/-0)
tests/data/probert_storage_raid1_partitions.json (+951/-0)
tests/data/probert_storage_zlp6.json (+6980/-0)
tests/unittests/test_block.py (+26/-0)
tests/unittests/test_block_dasd.py (+1/-1)
tests/unittests/test_block_multipath.py (+87/-6)
tests/unittests/test_block_zfs.py (+26/-0)
tests/unittests/test_clear_holders.py (+131/-11)
tests/unittests/test_commands_block_meta.py (+377/-36)
tests/unittests/test_commands_collect_logs.py (+3/-1)
tests/unittests/test_curthooks.py (+311/-26)
tests/unittests/test_distro.py (+71/-0)
tests/unittests/test_storage_config.py (+114/-9)
tests/unittests/test_udev.py (+15/-14)
tests/unittests/test_util.py (+41/-1)
tests/vmtests/__init__.py (+231/-23)
tests/vmtests/helpers.py (+11/-6)
tests/vmtests/releases.py (+34/-0)
tests/vmtests/test_apt_config_cmd.py (+1/-4)
tests/vmtests/test_basic.py (+71/-81)
tests/vmtests/test_basic_dasd.py (+8/-10)
tests/vmtests/test_bcache_basic.py (+5/-0)
tests/vmtests/test_bcache_bug1718699.py (+5/-0)
tests/vmtests/test_bcache_ceph.py (+31/-0)
tests/vmtests/test_bcache_partitions.py (+5/-0)
tests/vmtests/test_fs_battery.py (+5/-0)
tests/vmtests/test_iscsi.py (+6/-0)
tests/vmtests/test_journald_reporter.py (+5/-4)
tests/vmtests/test_lvm.py (+15/-18)
tests/vmtests/test_lvm_iscsi.py (+5/-0)
tests/vmtests/test_lvm_raid.py (+4/-0)
tests/vmtests/test_lvm_root.py (+16/-1)
tests/vmtests/test_mdadm_bcache.py (+92/-12)
tests/vmtests/test_mdadm_iscsi.py (+5/-0)
tests/vmtests/test_multipath.py (+6/-0)
tests/vmtests/test_network.py (+4/-0)
tests/vmtests/test_network_alias.py (+5/-0)
tests/vmtests/test_network_bonding.py (+4/-0)
tests/vmtests/test_network_bridging.py (+23/-0)
tests/vmtests/test_network_ipv6_static.py (+4/-0)
tests/vmtests/test_network_ipv6_vlan.py (+8/-0)
tests/vmtests/test_network_mtu.py (+42/-10)
tests/vmtests/test_network_static.py (+4/-0)
tests/vmtests/test_network_static_routes.py (+5/-0)
tests/vmtests/test_network_vlan.py (+12/-0)
tests/vmtests/test_nvme.py (+5/-0)
tests/vmtests/test_old_apt_features.py (+3/-2)
tests/vmtests/test_pollinate_useragent.py (+5/-0)
tests/vmtests/test_preserve.py (+5/-0)
tests/vmtests/test_preserve_raid.py (+5/-0)
tests/vmtests/test_raid5_bcache.py (+5/-0)
tests/vmtests/test_reuse_raid_member.py (+63/-0)
tests/vmtests/test_simple.py (+16/-1)
tests/vmtests/test_uefi_basic.py (+11/-1)
tests/vmtests/test_zfsroot.py (+18/-2)
tools/block-discover-to-config (+3/-1)
tools/jenkins-runner (+50/-0)
tools/vmtest-filter (+12/-1)
tools/vmtest-sync-images (+15/-13)
tools/xkvm (+20/-4)
tags: | added: multipath |
Changed in curtin: | |
status: | Confirmed → In Progress |
Changed in curtin: | |
assignee: | nobody → Ryan Harper (raharper) |
https:/ /wiki.ubuntu. com/FSTAB