From 5d716ef4ec67ccc84c85c88a33de098298861981 Mon Sep 17 00:00:00 2001 From: Faruk Kasumovic Date: Fri, 6 Jul 2018 13:35:47 +0200 Subject: [PATCH] Additional compatibility changes to work with libzfs 0.7.x --- common.go | 3 +++ zpool.go | 6 ++++++ 2 files changed, 9 insertions(+) diff --git a/common.go b/common.go index f23aac7..02678d8 100644 --- a/common.go +++ b/common.go @@ -90,8 +90,11 @@ const ( PoolStatusFailingDev /* device experiencing errors */ PoolStatusVersionNewer /* newer on-disk version */ PoolStatusHostidMismatch /* last accessed by another system */ + PoolStatusHosidActive /* currently active on another system */ + PoolStatusHostidRequired /* multihost=on and hostid=0 */ PoolStatusIoFailureWait /* failed I/O, failmode 'wait' */ PoolStatusIoFailureContinue /* failed I/O, failmode 'continue' */ + PoolStatusIOFailureMap /* ailed MMP, failmode not 'panic' */ PoolStatusBadLog /* cannot read log chain(s) */ PoolStatusErrata /* informational errata available */ diff --git a/zpool.go b/zpool.go index a7b3f30..d45e526 100644 --- a/zpool.go +++ b/zpool.go @@ -1111,10 +1111,16 @@ func (s PoolStatus) String() string { return "VERSION_NEWER" case PoolStatusHostidMismatch: /* last accessed by another system */ return "HOSTID_MISMATCH" + case PoolStatusHosidActive: /* currently active on another system */ + return "HOSTID_ACTIVE" + case PoolStatusHostidRequired: /* multihost=on and hostid=0 */ + return "HOSTID_REQUIRED" case PoolStatusIoFailureWait: /* failed I/O, failmode 'wait' */ return "FAILURE_WAIT" case PoolStatusIoFailureContinue: /* failed I/O, failmode 'continue' */ return "FAILURE_CONTINUE" + case PoolStatusIOFailureMap: /* ailed MMP, failmode not 'panic' */ + return "HOSTID_FAILURE_MAP" case PoolStatusBadLog: /* cannot read log chain(s) */ return "BAD_LOG" case PoolStatusErrata: /* informational errata available */