summaryrefslogtreecommitdiffstats
path: root/sys/cddl/contrib/opensolaris/uts
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2007-04-17 17:57:34 +0000
committerpjd <pjd@FreeBSD.org>2007-04-17 17:57:34 +0000
commit934b1fc38b7f6579acc5a3c08451320417880ce3 (patch)
tree7662d3bb71e390d6c2dcb9bd8ecec00daeb1c697 /sys/cddl/contrib/opensolaris/uts
parentf0a8f88e532b914ad68f0db198a54742e4e28c27 (diff)
downloadFreeBSD-src-934b1fc38b7f6579acc5a3c08451320417880ce3.zip
FreeBSD-src-934b1fc38b7f6579acc5a3c08451320417880ce3.tar.gz
Ignore hostid check for root-on-ZFS configurations. Making hostid available
before the root is mounted is tricky and having it in /boot/ is not really desire. Reported by: Zephiris <zephiris@gmail.com>
Diffstat (limited to 'sys/cddl/contrib/opensolaris/uts')
-rw-r--r--sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c
index 0e649bb..f8d9465 100644
--- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c
+++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c
@@ -598,8 +598,12 @@ spa_load(spa_t *spa, nvlist_t *config, spa_load_state_t state, int mosconfig)
goto out;
}
+ /*
+ * hostid is set after the root file system is mounted, so
+ * ignore the check until it's done.
+ */
if (nvlist_lookup_uint64(newconfig, ZPOOL_CONFIG_HOSTID,
- &hostid) == 0) {
+ &hostid) == 0 && root_mounted()) {
char *hostname;
unsigned long myhostid = 0;
OpenPOWER on IntegriCloud