X-Git-Url: https://code.delx.au/monosys/blobdiff_plain/36d0a55131f0a06f9cbaffaf5309880644e9f2af..bed319aa57a972353f91ae7ab2ec652193ce21d0:/zfs/bsnap diff --git a/zfs/bsnap b/zfs/bsnap index 6c9194d..fa6b5af 100755 --- a/zfs/bsnap +++ b/zfs/bsnap @@ -6,9 +6,13 @@ function snap { unsnap znap-list | xargs -n1 znap-mount /a + mkdir -p /a/boot + mount --bind /boot /a/boot } function unsnap { + umount /a/boot || true + rmdir /a/boot || true znap-umount-all /a } @@ -17,8 +21,6 @@ if [ "$(id -u)" -ne 0 ]; then exit 1 fi -mkdir -p /a - if [ "${1:-}" = "off" ]; then unsnap elif [ "${1:-}" = "on" ]; then