forked from third-party-mirrors/zfs_autobackup
older zpool command doesnt support -o
This commit is contained in:
parent
3bc37d143c
commit
4d15f29b5b
@ -500,15 +500,15 @@ class ZfsPool():
|
|||||||
self.debug("Getting zpool properties")
|
self.debug("Getting zpool properties")
|
||||||
|
|
||||||
cmd=[
|
cmd=[
|
||||||
"zpool", "get", "-H", "-o", "property,value", "-p", "all", self.name
|
"zpool", "get", "-H", "-p", "all", self.name
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
ret={}
|
ret={}
|
||||||
|
|
||||||
for pair in self.zfs_node.run(tab_split=True, cmd=cmd, readonly=True, valid_exitcodes=[ 0 ]):
|
for pair in self.zfs_node.run(tab_split=True, cmd=cmd, readonly=True, valid_exitcodes=[ 0 ]):
|
||||||
if len(pair)==2:
|
if len(pair)==4:
|
||||||
ret[pair[0]]=pair[1]
|
ret[pair[1]]=pair[2]
|
||||||
|
|
||||||
return(ret)
|
return(ret)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user