- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- compiling nagios plugins
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-09-2007 10:51 PM
01-09-2007 10:51 PM
compiling nagios plugins
The compilation stop at the check_swap phase.
How to fix this problem?
# make
.....
gcc -g -O2 -o check_swap check_swap.o utils.o popen.o -L/tmp/depot/nagios-plugins-1.4.5/plugins -L/opt/openssl/lib -lm ../lib/libnagiosplug.a ../lib/libcoreutils.a /
usr/local/lib/libintl.sl -L/usr/local/lib /usr/local/lib/libiconv.sl -lc -lssl -lcrypto -Wl,+b -Wl,/usr/local/lib
/usr/ccs/bin/ld: Unsatisfied symbols:
floorf (first referenced in check_swap.o) (code)
collect2: ld returned 1 exit status
*** Error exit code 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-09-2007 11:57 PM
01-09-2007 11:57 PM
Re: compiling nagios plugins
and welcome to the forums !
Problem is down to missing/wrong library or header file. Double check all your LIB_PATHs.
Try to add -lm math.h
For more details on this error:
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1374705&group_id=29880
Please also read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#33 on how to reward any useful answers given to your questions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2007 07:59 PM
01-15-2007 07:59 PM
Re: compiling nagios plugins
how are you getting on with theis problem ?
Could you please complete the thread by awarding points to helpful answers and summarising the solution for you.
This will help resolution of similar problems in the future.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2007 11:11 PM
01-15-2007 11:11 PM
Re: compiling nagios plugins
maybe it helps You that there are precompiled nagios plugins for HP-UX at the 'nagios exchange'
http://www.nagiosexchange.org/HP-UX.81.0.html?&tx_netnagext_pi1[p_view]=40
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2007 11:38 PM
01-15-2007 11:38 PM
Re: compiling nagios plugins
And I find that it far better suits my admin needs than so called professional suites like Tivoli (which we I regret to admit have also wasted money on).
You can indeed get prebuilt binaries for many platforms from nagiosexchange, as someone suggested.
However, these are seldomly very much up to date.
Nevertheless, the most fundamental Nagios plug-ins do compile quite easily.
If you don't have any requirement to check swap on your HP-UX hosts by the check_swap plug-in simply skip it.
It's also very easy to write your own plug-in for HP-UX swap state queries, which even would be better suited I would guess.
Either comment the target entry for check_swap in the Makefile and continue.
Or make the remaining plug-ins individually.
There is no special make install required for Nagios plug-ins.
Most of the post-compile commands involves merely things like creating symlinks to check_tcp and check_icmp (which are the two most important plug-ins, as far as the Nagios server is concerned).
If your make aborted due to the swap dificulties, I would suggest to check that check_icmp is owned by root and has the suid bit set (because only root may emit ICMP packets).
Also check that check_host is a sym or hard link to check_icmp, and define check_host as the default check command for your host checks (but *don't* define a check_interval for host checks, as it would subvert Nagios'es own scheduling of host checks and severly degrade performance!).
The check_host guise is special because it is faster than check_icmp as it would only wait for the 1st ICMP packet to return to verify an host OK state and don't linger for any other packets to return.
Is your Nagios server an HP-UX box,
or only your monitored hosts?
In the latter case you would also require some "agent" like the NRPE (also available from nagiosexchange) that would perform the check_swap on behalf of the Nagios server.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2007 08:20 PM
01-16-2007 08:20 PM
Re: compiling nagios plugins
All the programs in the plug-in directory
are successfully compiled.
However, I encounter error compiling check_dhcp in plugins-root directory.
# make
.....
Making all in plugins-scripts
Making all in plugins-root
if gcc -DLOCALEDIR=\"/usr/local/nagios/share/locale\" -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I../lib -I../intl -I../plugins -I/o
pt/openssl/include -I/opt/openssl/include -g -O2 -MT check_dhcp.o -MD -MP -MF ".deps/check_dhcp.Tpo" -c -o check_dhcp.o check_dhc
p.c; \
then mv -f ".deps/check_dhcp.Tpo" ".deps/check_dhcp.Po"; else rm -f ".deps/check_dhcp.Tpo"; exit 1; fi
In file included from /usr/include/net/if.h:234,
from check_dhcp.c:60:
/usr/include/net/if6.h:77: error: field 'iflru_addr' has incomplete type
/usr/include/net/if6.h:78: error: field 'iflru_dstaddr' has incomplete type
/usr/include/net/if6.h:118: error: field 'lifra_addr' has incomplete type
/usr/include/net/if6.h:119: error: field 'lifra_mask' has incomplete type
*** Error exit code 1
Since this is a client system, I don't need
the check_dhcp program. I deleted the plugin-root entry in the Makefile.
The compilation was then successful for the rest of the programs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2007 10:23 PM
07-24-2007 10:23 PM
Re: compiling nagios plugins
Add the following lines to nagios-plugins-1.4.5/plugins/common.h file
defined(__hpux__).
I think it will fix your compilation error.Even I got this error.
May i know What for you are compiling Nagios???As it is available on HP-UX(11iv1,11iv2,11iv3)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2007 11:26 AM
07-25-2007 11:26 AM
Re: compiling nagios plugins
The issue is that you need to put the -lm at the end of the link line, after you use it.
Hmm, that's not the case either. Looking at math.h, it seems that floorf isn't available on PA and it's only there for IPF. So your solution of using floor, is the correct one.
/usr/include/net/if6.h:77: error: field 'iflru_addr' has incomplete type
This occurs because you haven't included
Caution, I'm not sure if that's 520 or a typo (for 500) since it don't see anyone setting it in
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2007 11:33 AM
07-25-2007 11:33 AM
Re: compiling nagios plugins
This was fixed with CR JAGaf64977 for 11.31.