mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-31 11:14:09 +03:00
contrib/dracut: zfs-lib: export_all: replace with inline zpool export -a
07a3312f17, which introduced this in October of 2014, didn't have zpool export -a available; we do Upstream-commit:6a41310c70Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Closes #13093
This commit is contained in:
@@ -121,22 +121,6 @@ for_relevant_root_children() {
|
||||
)
|
||||
}
|
||||
|
||||
# export_all OPTS
|
||||
# exports all imported zfs pools.
|
||||
export_all() {
|
||||
ret=0
|
||||
|
||||
IFS="${NEWLINE}"
|
||||
for pool in $(zpool list -H -o name) ; do
|
||||
if zpool list -H "${pool}" > /dev/null 2>&1; then
|
||||
zpool export "${pool}" "$@" || ret=$?
|
||||
fi
|
||||
done
|
||||
IFS="${OLDIFS}"
|
||||
|
||||
return ${ret}
|
||||
}
|
||||
|
||||
# ask_for_password
|
||||
#
|
||||
# Wraps around plymouth ask-for-password and adds fallback to tty password ask
|
||||
|
||||
Reference in New Issue
Block a user