-
Notifications
You must be signed in to change notification settings - Fork 79
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
OSD Permissions Denied when using OSD Check Plugins with Nagios 4.3.4 / NPRE 3.2.1 #36
Comments
What is the command you are using ? (e.g. |
[root@example ~ ]# /usr/local/nagios/libexec/check_ceph_osd --id nagios --keyring /etc/ceph/client.nagios.keyring -H 10.x.y.z -I 28 [root@example libexec]# su - nagios [nagios@example~]$ /usr/local/nagios/libexec/check_ceph_osd --id nagios --keyring /etc/ceph/client.nagios.keyring -H 10.x.y.z -I 28 [root@example] ceph auth list For security reasons, would prefer NOT to use the SUDO option to allow this command to run. |
It should be a file permission problem. Here is what I have for the user nagios:
|
Adjusting the permissions to the keyring file did help - but only when checking ceph locally. It is still failing with the error about permissions being denied when being run from NRPE. Xinetd has NRPE configured to run as user 'nagios'. Running Locally:[root@ceph1 libexec]# ./check_ceph_osd -H 10.x.y.z -i nagios -k /etc/ceph/client.nagios.keyring -I 0 Running through NRPE[root@nagios]# /usr/local/nagios/libexec/check_nrpe -H 10.x.y.z -c check_ceph_osd -a 10.x.y.z 0 NRPE config on CEPH Server for osd: |
So if I understand this NRPE line But there is a misunderstanding here. The plugin check_ceph_osd should not directly on the OSD, it should run on the same host where the local run is working (e.g. I'm sorry, we don't use NRPE here, but MRPE. And the plugin runs on the simple node, configured as a Ceph client. It is not a MON or OSD host, but just a node with the ceph-common package, and the correct /etc/ceph/ceph.conf file and the keyings. |
Yes, the check_nrpe command runs from the Nagios server - making a remote call to the CEPHX node, where it runs check_ceph_osd -H "CEPHX-IP Address" -I 0 |
When attempting to check OSD with Nagios using NRPE, I am getting the following error:
OSD ERROR: 2018-01-10 14:18:26.252441 7f67360c7700 -1 asok(0x7f6730001680) AdminSocketConfigObs::init: failed: AdminSocket::bind_and_listen: failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.nagios.1784273.140081163671472.asok': (13) Permission denied .
I have followed the documentation where we create the keyring file for nagios:
ceph auth get-or-create client.nagios mon 'allow r' > /etc/ceph/client.nagios.keyring
thank you
Karl Birkland
The text was updated successfully, but these errors were encountered: