Mercurial > illumos > illumos-gate
changeset 7706:75cbbfb9ce50
6716241 Changing hostid, by moving in a new sysinit file, panics a zfs root file system
author | Lin Ling <Lin.Ling@Sun.COM> |
---|---|
date | Fri, 26 Sep 2008 09:29:22 -0700 |
parents | a1475c6145e2 |
children | e1c04e8c2986 |
files | usr/src/uts/common/fs/zfs/spa.c |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/usr/src/uts/common/fs/zfs/spa.c Fri Sep 26 07:59:19 2008 -0700 +++ b/usr/src/uts/common/fs/zfs/spa.c Fri Sep 26 09:29:22 2008 -0700 @@ -1141,8 +1141,8 @@ goto out; } - if (nvlist_lookup_uint64(newconfig, ZPOOL_CONFIG_HOSTID, - &hostid) == 0) { + if (!spa_is_root(spa) && nvlist_lookup_uint64(newconfig, + ZPOOL_CONFIG_HOSTID, &hostid) == 0) { char *hostname; unsigned long myhostid = 0; @@ -1154,7 +1154,7 @@ (unsigned long)hostid != myhostid) { cmn_err(CE_WARN, "pool '%s' could not be " "loaded as it was last accessed by " - "another system (host: %s hostid: 0x%lx). " + "another system (host: %s hostid: 0x%lx). " "See: http://www.sun.com/msg/ZFS-8000-EY", spa->spa_name, hostname, (unsigned long)hostid);