467e6d641eb357c56d80944550b9e666743e0372
Hot spares have no error counters in the output of 'zpool status', so a spare that is in use only has a message after its state: nvme10n1 INUSE currently in use The parser took the three words of that message as READ, WRITE and CKSUM counters, so the API returned zero for all of them and lost the message, while logging warnings like: Argument "currently" isn't numeric in addition (+) As 'zpool status' is called with '-p', the counters are always plain numbers, so only accept digits for them. This way, the message of a spare in use ends up in 'msg', like for any other vdev. Signed-off-by: Michal Fox <me@dualfroz.com>
Description
My contributions to proxmox-git/pve-storage: 8 commits
101 KiB
0 Stars
1 Watchers
0 Forks
Languages
Perl
100%