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>
This commit is contained in:
Pawel Jakub Dawidek 2007-04-17 17:57:34 +00:00
parent c859cda5eb
commit 39db4c6e0f
2 changed files with 10 additions and 2 deletions

View File

@ -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;

View File

@ -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;