[Bug 251086] bsdinstall doesn't copy /BSDINSTALL_TMPBOOT/zfs/zpool.cache
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Thu Nov 12 21:59:44 UTC 2020
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=251086
Bug ID: 251086
Summary: bsdinstall doesn't copy
/BSDINSTALL_TMPBOOT/zfs/zpool.cache
Product: Base System
Version: 12.2-RELEASE
Hardware: Any
OS: Any
Status: New
Severity: Affects Only Me
Priority: ---
Component: bin
Assignee: bugs at FreeBSD.org
Reporter: parakleta at darkreality.org
In the `bsdinstall/config` script there is the line:
cp $BSDINSTALL_TMPBOOT/* $BSDINSTALL_CHROOT/boot
which fails to copy the `/boot/zfs/zpool.cache` file. This is fine if you only
have a single boot zpool, but leads to import failures after install if you
have other pools.
Note that relatedly the `bsdinstall/partedit/gpart_ops.c` file specifically
creates the `zpool.cache` file here:
if (getenv("BSDINSTALL_TMPBOOT") != NULL) {
char zfsboot_path[MAXPATHLEN];
snprintf(zfsboot_path, sizeof(zfsboot_path), "%s/zfs",
getenv("BSDINSTALL_TMPBOOT"));
mkdir(zfsboot_path, S_IRWXU | S_IRGRP | S_IXGRP |
S_IROTH | S_IXOTH);
sprintf(command, "%s -o cachefile=%s/zpool.cache ",
command, zfsboot_path);
}
I suggest that the `cp` should be `cp -R` or `cp -a` instead.
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-bugs
mailing list