diff options
author | Franck Bui <fbui@suse.com> | 2018-02-28 10:36:06 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2018-02-28 10:36:06 +0100 |
commit | f8adf25d658a9c3965e2c88d241aefeabf5de601 (patch) | |
tree | 3b57e22b0570ee0f68fbcf0864775009131ce33b /rules | |
parent | 81818461c655a5c3adec4f3bc221aa986d9c65b6 (diff) | |
download | systemd-f8adf25d658a9c3965e2c88d241aefeabf5de601.tar.gz |
rules: skip btrfs check if devices are not ready in 64-btrfs.rules (#8304)
If any devices are marked with 'SYSTEMD_READY=0' then we shouldn't run any
btrfs check on them.
Indeed there's no point in running "btrfs ready" on devices that already have
SYSTEMD_READY=0 set. Most probably such devices are members of a higher layer
aggregate device such as dm-multipath or software RAID. Doing IO on them wastes
time at best, and may cause delays, timeouts, or even hangs at worst (think
active-passive multipath or degraded RAID, for example).
It was initially reported at:
https://bugzilla.opensuse.org/show_bug.cgi?id=872929
Diffstat (limited to 'rules')
-rw-r--r-- | rules/64-btrfs.rules.in | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/rules/64-btrfs.rules.in b/rules/64-btrfs.rules.in index c3a0972f2e..aad29afb8b 100644 --- a/rules/64-btrfs.rules.in +++ b/rules/64-btrfs.rules.in @@ -3,6 +3,7 @@ SUBSYSTEM!="block", GOTO="btrfs_end" ACTION=="remove", GOTO="btrfs_end" ENV{ID_FS_TYPE}!="btrfs", GOTO="btrfs_end" +ENV{SYSTEMD_READY}=="0", GOTO="btrfs_end" # let the kernel know about this btrfs filesystem, and check if it is complete IMPORT{builtin}="btrfs ready $devnode" |