Trouble installing a plugin

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Trouble installing a plugin

Post by angus »

Hello,

I am having issues installing the plug in listed below. I attempted the install instructions on their readme but it seems some of the files are missing. It may also be that i have made a mistake. Can someone assist me?

The Plugin
https://github.com/thecodeteam/nagios-unity

The error i am getting at install:
No local packages or download links found for docopt>=0.6.2
error: Could not find suitable distribution for Requirement.parse('docopt>=0.6.2')

Thanks.
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Trouble installing a plugin

Post by npolovenko »

@angus, Have you used the pip instructions or the git instructions to install the plugin? What is the version of your OS?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Re: Trouble installing a plugin

Post by angus »

I used the python setup below. I manually download the package and unzipped it in the /tmp dir. I am using Centos. I am not familiar with the PIP install options. Should i investigate PIP and go that route?
$ cd nagios-unity
$ sudo python setup.py install
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Trouble installing a plugin

Post by npolovenko »

@angus, Not really, I only asked that so I could go the same route and try to reproduce the problem.
You should install the docopt package:

Code: Select all

pip install docopt==0.6.2
If you don't have pip you need to install it:

Code: Select all

easy_install pip
Let me know how it goes.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Re: Trouble installing a plugin

Post by angus »

Once I installed via PIP, i attempt to use the commands but i get an odd response. What is going on here?

/]# nagios-unity --help
Traceback (most recent call last):
File "/usr/bin/nagios-unity", line 5, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 2655, in <module>
working_set.require(__requires__)
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 648, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 546, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: urllib3>=1.21.1


Thanks.
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Trouble installing a plugin

Post by npolovenko »

@angus, You may still be missing some of the required modules. Please run this command:

Code: Select all

pip install urllib3
I installed the plugin with one command:

Code: Select all

 pip install nagios-unity
And it seemed like python automatically downloaded all the dependent packages for me.
So then i ran:

Code: Select all

/usr/bin/nagios-unity -help
And haven't gotten any errors.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Re: Trouble installing a plugin

Post by angus »

Even after performing those commands, i still have the same issue.

~]# /usr/bin/nagios-unity -help
Traceback (most recent call last):
File "/usr/bin/nagios-unity", line 5, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 2655, in <module>
working_set.require(__requires__)
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 648, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 546, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: urllib3>=1.21.1
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Re: Trouble installing a plugin

Post by angus »

I removed the two packages, urllib3 and nagios-unity, and reinstalled them. now i get a new set of errors.

/]# nagios-unity
Traceback (most recent call last):
File "/usr/bin/nagios-unity", line 7, in <module>
from nagiosunity.cli.client import main
File "/usr/lib/python2.6/site-packages/nagiosunity/cli/client.py", line 52, in <module>
from nagiosunity.lib import utils
File "/usr/lib/python2.6/site-packages/nagiosunity/lib/utils.py", line 17, in <module>
import bitmath
File "/usr/lib/python2.6/site-packages/bitmath/__init__.py", line 58, in <module>
import argparse
ImportError: No module named argparse

Thanks.
angus
Posts: 125
Joined: Thu May 28, 2015 8:17 am

Re: Trouble installing a plugin

Post by angus »

I installed python-argparse manually and am now presented with the following:

]# /usr/bin/nagios-unity -help
Traceback (most recent call last):
File "/usr/bin/nagios-unity", line 7, in <module>
from nagiosunity.cli.client import main
File "/usr/lib/python2.6/site-packages/nagiosunity/cli/client.py", line 54, in <module>
from nagiosunity import commands
File "/usr/lib/python2.6/site-packages/nagiosunity/commands/__init__.py", line 47
commands_dict = {cmd.name: cmd for cmd in COMMANDS}
^
SyntaxError: invalid syntax

Thanks.
kyang

Re: Trouble installing a plugin

Post by kyang »

Thanks for posting the errors, but since this isn't a plugin available in our nagios-plugins package.

It's probably best if you report these issues to the maintainer of this plugin.
https://github.com/thecodeteam/nagios-unity/issues

The last commit was in Dec 2017, so they seem fairly on point in terms of updates.
Locked