Page 1 of 1

MUNIN zfs plugins require root access

Posted: Sun Nov 08, 2015 12:43 am
by gilthanaz
[Problem]
After linking two zfs plugins for munin, they could not be executed as the zfs and zpool commands require root priviledges. I checked out the scripts from https://github.com/munin-monitoring/con ... lugins/zfs and linked them as usual into the munin plugins directory:

Code: Select all

/etc/munin/plugins/zfs_cache_efficiency
/etc/share/munin/plugins/zfs_list
The munin user does not have enough privileges, tho:

Code: Select all

$ zpool status
Permission denied the ZFS utilities must be run as root.
[Solution]
The needed info needs to be configured in /etc/munin/plugin-conf.d/munin-node by adding:

Code: Select all

[zfs_list]
user root

[zfs_cache_efficiency]
user root
The plugins worked great after munin was aware that they need to be executed with root privileges and even offered more functionality than i was expecting, including data on how much space is used by snapshots and how good a cache device is used.