aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorThijs Cramer <[email protected]>2016-02-04 22:34:49 +0100
committerBrian Behlendorf <[email protected]>2016-03-09 10:41:23 -0800
commit95003f709859fd104aad258e56bcc4dc5c8cfcf0 (patch)
tree2ca032505f153d49c653ead14cbcd05ff82881b1 /lib
parent7d11e37e5502e4dc473a9fe073779823d6ca2495 (diff)
Updated paths to scan when importing zpool(s)
Added by-partlabel and by-partuuid to the default device search path. Made made device names in by-label more preferable. Signed-off-by: Thijs Cramer <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #3892
Diffstat (limited to 'lib')
-rw-r--r--lib/libzfs/libzfs_import.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libzfs/libzfs_import.c b/lib/libzfs/libzfs_import.c
index d2eefff53..e4d0d37e4 100644
--- a/lib/libzfs/libzfs_import.c
+++ b/lib/libzfs/libzfs_import.c
@@ -1273,10 +1273,12 @@ char *
zpool_default_import_path[DEFAULT_IMPORT_PATH_SIZE] = {
"/dev/disk/by-vdev", /* Custom rules, use first if they exist */
"/dev/mapper", /* Use multipath devices before components */
+ "/dev/disk/by-partlabel", /* Single unique entry set by user */
+ "/dev/disk/by-partuuid", /* Generated partition uuid */
+ "/dev/disk/by-label", /* Custom persistent labels */
"/dev/disk/by-uuid", /* Single unique entry and persistent */
"/dev/disk/by-id", /* May be multiple entries and persistent */
"/dev/disk/by-path", /* Encodes physical location and persistent */
- "/dev/disk/by-label", /* Custom persistent labels */
"/dev" /* UNSAFE device names will change */
};