NCPA: Linux Install on OpenVZ

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
mikew
Posts: 243
Joined: Sun Feb 05, 2012 7:05 pm

NCPA: Linux Install on OpenVZ

Post by mikew »

Installing NCPA for Linux on a CentOS 6 virtual machine using OpenVZ for virtualization. The install fails because /proc/partitions does not exist. Is there an alternative that I can modify the script to get it to install?

Code: Select all

Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/cx_Freeze/initscripts/Console.py", line 27, in <module>
  File "ncpa_posix_listener.py", line 7, in <module>
  File "/build/ncpa/agent/listener/server.py", line 14, in <module>
  File "/build/ncpa/agent/listener/psapi.py", line 141, in <module>
  File "/usr/lib/python2.6/site-packages/psutil/__init__.py", line 1227, in disk_io_counters
  File "/usr/lib/python2.6/site-packages/psutil/_pslinux.py", line 376, in disk_io_counters
IOError: [Errno 2] No such file or directory: '/proc/partitions'
I am using OpenVZ for virtualization and there is no /proc/partitions.

Code: Select all

ls /proc
1      14130  15548  16105    cpuinfo      kmsg     modules  stat           sysvipc            vmstat
13888  14138  15667  16108    devices      loadavg  mounts   swaps          uptime             vz
14109  14139  16084  22218    filesystems  locks    net      sys            user_beancounters
14123  14203  16100  cmdline  fs           meminfo  self     sysrq-trigger  version

Code: Select all

df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/simfs             2581260    712832   1868428  28% /
none                   1087956         4   1087952   1% /dev

Code: Select all

cat /proc/mounts
/dev/simfs / simfs rw 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
none /dev tmpfs rw 0 0
none /dev/pts devpts rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0
Is there a 64-bit version of the NCPA install?

The other failure I am getting on other machines with /proc/partitions tested is this, which I believe indicates I need a 64-bit RPM:

Code: Select all

/etc/init.d/ncpa_listener: /usr/local/ncpa/ncpa_posix_listener: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
Started listener...
/etc/init.d/ncpa_passive: /usr/local/ncpa/ncpa_posix_passive: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
Started passive agent.
..
Mike Weber

Nagios Training/Consulting
User avatar
nscott
Posts: 1040
Joined: Wed May 11, 2011 8:54 am

Re: NCPA: Linux Install on OpenVZ

Post by nscott »

Yeah that is absolutely the case. It must be built for 64 bit CentOS 6. I'll see if I can get around to doing that today.
Nicholas Scott
Former Nagios employee
User avatar
nscott
Posts: 1040
Joined: Wed May 11, 2011 8:54 am

Re: NCPA: Linux Install on OpenVZ

Post by nscott »

Mike, I have updated the how to install NCPA documentation, and have added RPMs for x86_64 for both CentOS 6 and CentOS 5. Can you see if these fix your issue?

/Nick
Nicholas Scott
Former Nagios employee
User avatar
mikew
Posts: 243
Joined: Sun Feb 05, 2012 7:05 pm

Re: NCPA: Linux Install on OpenVZ

Post by mikew »

I set it up on a 64-bit system, CentOS 6.4 and could not get it to work. Here is the log:

Code: Select all

Traceback (most recent call last):
  File "ncpa_posix_listener.py", line 34, in run
  File "/usr/lib/python2.6/site-packages/flask/app.py", line 772, in run
  File "/usr/lib/python2.6/site-packages/werkzeug/serving.py", line 710, in run_simple
  File "/usr/lib/python2.6/site-packages/werkzeug/serving.py", line 692, in inner
  File "/usr/lib/python2.6/site-packages/werkzeug/serving.py", line 486, in make_server
  File "/usr/lib/python2.6/site-packages/werkzeug/serving.py", line 410, in __init__
  File "/usr/lib64/python2.6/SocketServer.py", line 402, in __init__
    self.server_bind()
  File "/usr/lib64/python2.6/BaseHTTPServer.py", line 108, in server_bind
    SocketServer.TCPServer.server_bind(self)
  File "/usr/lib64/python2.6/SocketServer.py", line 413, in server_bind
    self.socket.bind(self.server_address)
  File "<string>", line 1, in bind
error: [Errno 98] Address already in use
2013-10-21 22:22:40,864 6568 INFO stopped
Port 5693 is not listening, ports 80 and 443 are up. I stopped and started the daemon several times.
Mike Weber

Nagios Training/Consulting
User avatar
nscott
Posts: 1040
Joined: Wed May 11, 2011 8:54 am

Re: NCPA: Linux Install on OpenVZ

Post by nscott »

Ok there was an error in the OpenSSL build on that box. Please give it another go, I've tested it working on fresh installs so it should work for you.

/Nick
Nicholas Scott
Former Nagios employee
User avatar
mikew
Posts: 243
Joined: Sun Feb 05, 2012 7:05 pm

Re: NCPA: Linux Install on OpenVZ

Post by mikew »

That fixed one problem...I now can install and it is up and running. I used the new wizard to install. I assume the wizard will be expanded for disk, etc. as it is very limited at this point.

Here is an image of the results. The data seems correct but all states remain in unknown.
[attachment=0]ncpa_error.png[/attachment}

I have also tried to download the Windows version, as I wanted to test that as well. The link in the PDF does not seem to work. I would want a 64-bit version to install on Windows 2012 or 2008.

Thanks for your help.
You do not have the required permissions to view the files attached to this post.
Mike Weber

Nagios Training/Consulting
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: NCPA: Linux Install on OpenVZ

Post by slansing »

Mike, what is the full output of running one of your configured commands manually from the CLI? Is it showing the unknown state in the output? Or the true state of what is being checked off your thresholds?
Locked