New check_snmp in CVS

Andrew Cruse andrew at profitability.net
Mon Jul 25 23:13:39 CEST 2005


Subhendu Ghosh wrote:
 >> That may be part of the problem -- I have two installations:
>> 
>> [root at monitor2 nagios-plugins-1.4]# /usr/local/bin/snmpwalk -V
>> NET-SNMP version: 5.2.1 [root at monitor2 nagios-plugins-1.4]#
>> /usr/bin/snmpwalk -V UCD-snmp version: 4.2.5 
> 
> When you run configure - make sure the /usr/local/bin is
> earlier in the path so the newer version of snmp* will get selected.

It looks like it's finding the right version:

checking for snmpget... /usr/local/bin/snmpget
checking for snmpgetnext... /usr/local/bin/snmpgetnext
checking for Net::SNMP perl module... found

But still errors out.  Just for my sanity, I tried compiling it on two
other systems.  One is the same OS (RH 7.3) as the original system, the
other a more modern OS (RHEL3) each with varying versions of net-snmp.
Both other systems errored out with this:

source='check_snmp.c' object='check_snmp.o' libtool=no \
depfile='.deps/check_snmp.Po' tmpdepfile='.deps/check_snmp.TPo' \
depmode=gcc3 /bin/sh ../depcomp \
gcc -DHAVE_CONFIG_H -I. -I. -I. -I. -I. -I. -I. -I. -I.. -I../lib
-I/usr/include/ldap  -I/usr/include   -I/usr/kerberos/include  -g -O2 -c
`test -f 'check_snmp.c' || echo './'`check_snmp.c
check_snmp.c: In function `main':
check_snmp.c:145: `LC_ALL' undeclared (first use in this function)
check_snmp.c:145: (Each undeclared identifier is reported only once
check_snmp.c:145: for each function it appears in.)
check_snmp.c:146: `LOCALEDIR' undeclared (first use in this function)
check_snmp.c:189: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:195: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:301: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c: In function `process_arguments':
check_snmp.c:432: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c:479: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c:487: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c:498: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c:510: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c:556: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c: In function `validate_arguments':
check_snmp.c:707: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:716: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:726: warning: passing arg 1 of `usage2' makes pointer from
integer without a cast
check_snmp.c: In function `print_help':
check_snmp.c:901: `COPYRIGHT' undeclared (first use in this function)
check_snmp.c:903: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:908: `UT_HELP_VRSN' undeclared (first use in this function)
check_snmp.c:908: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:910: `UT_HOST_PORT' undeclared (first use in this function)
check_snmp.c:910: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:913: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:924: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:936: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:948: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:955: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:966: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:972: `UT_TIMEOUT' undeclared (first use in this function)
check_snmp.c:972: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:974: `UT_VERBOSE' undeclared (first use in this function)
check_snmp.c:974: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:976: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:981: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:985: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:991: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:995: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
check_snmp.c:1003: `UT_SUPPORT' undeclared (first use in this function)
check_snmp.c:1003: warning: passing arg 1 of `printf' makes pointer from
integer without a cast
make[2]: *** [check_snmp.o] Error 1

Thanks,

Andrew




-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list