diff options
author | James Lee <[email protected]> | 2015-09-19 22:00:36 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2015-10-13 10:37:05 -0700 |
commit | 33df62d052bad11a1ebb220810672fcfba2a8d86 (patch) | |
tree | fbc78fd25a2411397125944217ed22479174e988 /module/zfs/dmu_objset.c | |
parent | 2986b3fd2587b1da5b6047a5c0b6bbb0b6d9c47e (diff) |
zfs-import: Perform verbatim import using cache file
This change modifies the import service to use the default cache file
to perform a verbatim import of pools at boot. This fixes code that
searches all devices and imported all visible pools.
Using the cache file is in keeping with the way ZFS has always worked,
how Solaris, Illumos, FreeBSD, and systemd performs imports, and is how
it is written in the man page (zpool(1M,8)):
All pools in this cache are automatically imported when the
system boots.
Importantly, the cache contains important information for importing
multipath devices, and helps control which pools get imported in more
dynamic environments like SANs, which may have thousands of visible
and constantly changing pools, which the ZFS_POOL_EXCEPTIONS variable
is not equipped to handle. Verbatim imports prevent rogue pools from
being automatically imported and mounted where they shouldn't be.
The change also stops the service from exporting pools at shutdown.
Exporting pools is only meant to be performed explicitly by the
administrator of the system.
The old behavior of searching and importing all visible pools is
preserved and can be switched on by heeding the warning and toggling
the ZPOOL_IMPORT_ALL_VISIBLE variable in /etc/default/zfs.
Signed-off-by: James Lee <[email protected]>
Signed-off-by: Richard Yao <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #3777
Closes #3526
Diffstat (limited to 'module/zfs/dmu_objset.c')
0 files changed, 0 insertions, 0 deletions