Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

when multiple zpool, method ZFS.zpools tries to create only one ZPool object #2

Open
xarou opened this issue Jul 13, 2017 · 1 comment

Comments

@xarou
Copy link

xarou commented Jul 13, 2017

I've manage to fix this issue modifying the parameters of the line method on line 6 of zpool.rb replaceing '' with "\n".

It might be intresting to check the operating system to ensure the right line separator is used.

Output without the fix ( with 2 zpools data and data_2)
$-> /opt/sensu/embedded/bin/ruby /opt/sensu/embedded/lib/ruby/gems/2.3.0/gems//sensu-plugins-zfs-1.2.3/bin/check-zpool.rb -s 31 -c 90 -C 90
sh: 2: data_2: not found
sh: 2: data_2: not found
sh: 2: data_2: not found
CheckZPool CRITICAL: zpool data
data_2 has state pool: data
state: ONLINE
...

@majormoses
Copy link
Member

Thanks for reporting and triaging this! This was recently transferred to the community and I have not had the time to really had the time to look through the code in depth. After #7 merges and releases would you be willing to put together a PR for this?

smuth4 added a commit to smuth4/sensu-plugins-zfs that referenced this issue Nov 15, 2017
Also re-order checks so the ones that can go critical are checked first
smuth4 added a commit to smuth4/sensu-plugins-zfs that referenced this issue Nov 15, 2017
Also re-order checks so the ones that can go critical are checked first
@smuth4 smuth4 mentioned this issue Nov 15, 2017
2 tasks
majormoses pushed a commit that referenced this issue Nov 16, 2017
* Fix checking all zpools (#2)

Also re-order checks so the ones that can go critical are checked first

* Properly issue critical errors first

* Display all errors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants