Re: CFV: Duplicate labels in lm_sensors

2015-02-25 Thread Jan Safranek
On 02/10/2015 04:21 PM, Jan Safranek wrote: > Solution 2: > Keep current behaviour and only when duplicate labels are detected, > prefix the later ones to keep them unique. > > lmTempSensorsDevice.2 = STRING: Core 0 > lmTempSensorsDevice.3 = STRING: Core 3 > lmTempSensorsDevi

CFV: Duplicate labels in lm_sensors

2015-02-10 Thread Jan Safranek
Our lmSensors MIB implementation(s) does not handle well multiple sensors with the same name. It simply ignores some of them. E.g. I have HW with two Xeon E7520 CPUs. lm_sensors says following: coretemp-isa- Adapter: ISA adapter Core 0: +41.0°C (high = +75.0°C, crit = +91.0°C) Core 3:

'proxy' out of tree behavior

2014-04-14 Thread Jan Safranek
Hi Wes, I've noticed that you changed proxy.c back in 2011, commit 4eb12f0e (SVN rev. 20371): Author: Wes Hardaker Date: Mon May 9 14:19:12 2011 + we actually want to use the base OID as the starting point, not the reg OID. [..snip..] --- a/agent/mibgroup/ucd-snmp/proxy.c +++ b/age

SNMPv3 and multithreading

2014-04-04 Thread Jan Safranek
Net-SNMP FAQ says that "... SNMPv3 support was never checked for multi-threading correctness. It is most likely that it is not thread-safe at this time". Is it still true? The page was last edited on 21 July 2009. http://www.net-snmp.org/wiki/index.php/FAQ:General_19 Jan

Slow dskTable & caching

2012-11-29 Thread Jan Safranek
I noticed that UCD-SNMP-MIB::dskTable is unusually slow with NFS mounts and net-snmp-5.7.2. The reason is new implementation of the table in agent/mibgroup/ucd-snmp/disk_hw.c. It re-reads filesystem info on every GET/GETNEXT request, see netsnmp_fsys_load() call in var_extensible_disk. The most si

CFV: Fix a typo in hrStorageTable

2012-10-09 Thread Jan Safranek
I accidentally checked in double-negation in fsys_mntent.c into V5-7-patches which is frozen now. Attached trivial patch fixes it. Jan diff --git a/agent/mibgroup/hardware/fsys/fsys_mntent.c b/agent/mibgroup/hardware/fsys/fsys_mntent.c index b9e6b64..3cbf1de 100644 --- a/agent/mibgroup/hardware/fs

Re: setting snmp source port number

2012-06-11 Thread Jan Safranek
On 05/06/2012 10:53 AM, Magnus Fromreide wrote: > On Sun, 2012-05-06 at 10:51 +0200, Magnus Fromreide wrote: >> On Sun, 2012-05-06 at 09:26 +0100, Dave Shield wrote: >>> On 6 May 2012 06:25, Magnus Fromreide wrote: On Fri, 2012-05-04 at 09:05 +, Durga Sree wrote: >>> >>> > Is it possi

Re: netsnmp_register_mib() error handling

2012-01-19 Thread Jan Safranek
On 01/18/2012 04:01 PM, Wes Hardaker wrote: >>>>>> On Tue, 17 Jan 2012 10:50:44 +0100, Jan Safranek >>>>>> said: > > JS> It's not that easy, agent_registry.c:1164 was only an example. There are > JS> other places, where the reginfo is n

Re: netsnmp_register_mib() error handling

2012-01-17 Thread Jan Safranek
On 01/16/2012 09:59 PM, Wes Hardaker wrote: >>>>>> On Thu, 12 Jan 2012 13:14:28 +0100, Jan Safranek >>>>>> said: > > JS> If the netsnmp_register_mib() function returns error, sometimes it frees > JS> its reginfo argument (agent_registry.c:1

netsnmp_register_mib() error handling

2012-01-12 Thread Jan Safranek
If the netsnmp_register_mib() function returns error, sometimes it frees its reginfo argument (agent_registry.c:1136) and sometimes not (agent_registry.c:1164). The caller does not know what to do and in most cases frees reginfo again (e.g. hrSWInstalledTable.c:144 and :166). I'd guess that netsnm

Reloading a perl subagent in embedded perl

2011-10-31 Thread Jan Safranek
I have a simple perl agent in embedded perl, let's say http://www.net-snmp.org/tutorial/tutorial-5/toolkit/perl/perl_module.pl and following config file: rocommunity public perl do "/path/to/perl_module.pl"; When I start the snmpd agent, it executes all 'perl do' statements and my subagent is reg

Re: libtool 2.4 and perl rpath

2011-10-06 Thread Jan Safranek
On 10/05/2011 06:50 PM, Bart Van Assche wrote: > On Wed, Oct 5, 2011 at 1:57 PM, Jan Safranek <mailto:jsafr...@redhat.com>> wrote: > > On 10/04/2011 08:09 PM, Bart Van Assche wrote:> $ readelf -a > ./agent/.libs/snmpd|grep perl > > 0x00

Re: libtool 2.4 and perl rpath

2011-10-05 Thread Jan Safranek
On 10/04/2011 08:09 PM, Bart Van Assche wrote: > On Tue, Oct 4, 2011 at 4:12 PM, Jan Safranek <mailto:jsafr...@redhat.com>> wrote: > > when I compile net-snmp-5.7 on Linux with embedded perl, I get missing > rpath in libnetsnmpmibs.so to perl: > >

libtool 2.4 and perl rpath

2011-10-04 Thread Jan Safranek
Hi, when I compile net-snmp-5.7 on Linux with embedded perl, I get missing rpath in libnetsnmpmibs.so to perl: ldd -r libnetsnmpmibs.so.30 ... libperl.so => not found The link command in agent/Makefile.in is (nearly) the same as in net-snmp-5.5, yet the 5.5 brach compiles libnets

Re: Proper solution for bug/patch 1633670

2011-08-30 Thread Jan Safranek
On 08/30/2011 12:40 PM, Bart Van Assche wrote: > On Tue, Aug 30, 2011 at 10:24 AM, Jan Safranek wrote: >> Problem is that you *must* dequeue all requests which are related to the >> closing AgentX session - somewhere deep in these requests there is >> pointer to the AgentX se

Re: Proper solution for bug/patch 1633670

2011-08-30 Thread Jan Safranek
On 08/29/2011 06:00 PM, Bart Van Assche wrote: > On Fri, Aug 26, 2011 at 1:40 PM, Jan Safranek wrote: >> I debugged bug 1633670 as far as I could and I have even a >> proof-of-concept patch, but I am not so happy with it. Could someone >> with better AgentX knowledge look at

Proper solution for bug/patch 1633670

2011-08-26 Thread Jan Safranek
Hi guys, I debugged bug 1633670 as far as I could and I have even a proof-of-concept patch, but I am not so happy with it. Could someone with better AgentX knowledge look at it? These parts look a bit fragile and I don't want to break them apart with wrong patch. Thanks in advance Jan -

SNMP daemons and systemd

2011-08-08 Thread Jan Safranek
As you may already know, systemd is new init systemd for Linux. It is in Fedora since F15 and it's heading to other distros as well. It's compatible with SysV init scripts, but it cannot use it's advanced features with them. See http://0pointer.de/public/systemd-man/daemon.html for details how sys

Re: CFV: fix rpm 4.9 support in 5.7.rc1

2011-06-20 Thread Jan Safranek
On 06/17/2011 08:05 PM, Bart Van Assche wrote: > On Fri, Jun 17, 2011 at 2:37 PM, Jan Safranek <mailto:jsafr...@redhat.com>> wrote: > > vanilla net-snmp 5.7.rc1 does not compile on Fedora 15 and rawhide. I > have quick & dirty specific patches in distro RPMs to

CFV: fix rpm 4.9 support in 5.7.rc1

2011-06-17 Thread Jan Safranek
Hi, vanilla net-snmp 5.7.rc1 does not compile on Fedora 15 and rawhide. I have quick & dirty specific patches in distro RPMs to make it work there. Now I finally got polished patches from Panu Matilainen, one of current RPM developers, which adds support of all RPM versions between 4.1 and 4.9 to

Re: CFV OID Ways Forward (was Re: Oid Type rationalization in 5.6.1)

2011-05-13 Thread Jan Safranek
On 05/13/2011 07:54 AM, Bart Van Assche wrote: > On Thu, May 12, 2011 at 3:57 PM, Niels Baggesen > wrote: >> On Thu, May 12, 2011 at 06:35:12AM -0700, Wes Hardaker wrote: >>> WH> A) produce 5.6.1.1 immediately >>> >>> I think that needs to be done (and fedora patched immediately for updates). >> >

Re: [PATCH] RFC: Recalculate storage units for big disks

2011-02-18 Thread Jan Safranek
On 02/08/2011 12:38 AM, Wes Hardaker wrote: >>>>>> On Mon, 31 Jan 2011 20:52:52 +0100, Jan Safranek >>>>>> said: > > JS> I can easily add new config token 'recalculateStorageUnits yes/no', > JS> probably off by default (=same behav

Re: [PATCH] RFC: Recalculate storage units for big disks

2011-01-31 Thread Jan Safranek
On 01/31/2011 07:52 PM, Wes Hardaker wrote: >> On Mon, 31 Jan 2011 11:59:45 -0500, Doug Manley >> said: > > DM> What team/committee is responsible for the HOST-RESOURCES MIB? > > It came out of the IETF. I've often thought that it needs a revmap, as > there are a number of issues with i

[PATCH] RFC: Recalculate storage units for big disks

2011-01-26 Thread Jan Safranek
Current hrStorageTable supports only 32bit hrStorageSize. With 4096 big allocation units, it supports disks up to 16 TB. These sizes are pretty common nowdays and I got few requests to do something about it. The only thing which comes to my mind is to lie about hrStorageAllocationUnits and report s

Re: rpm libraries (Was: SF.net SVN: net-snmp:[19892] trunk/net-snmp/configure.d)

2011-01-19 Thread Jan Safranek
On 01/19/2011 04:13 PM, Wes Hardaker wrote: > > JS> Make us compatible with rpm-4.9, rpmGetFilesystemList does not > JS> exist anymore, so the configure script should not check it. > > So what versions does the trunk compile against? It compiles with all that was working before + it detects rpm-

Re: Net-snmp 5.6 uses the wrong interface on a multi-homed box with asymmetric routing

2011-01-11 Thread Jan Safranek
On 12/22/2010 03:42 AM, Bill Fenner wrote: On Wed, Dec 15, 2010 at 4:28 AM, Jan Safranek wrote: On 12/13/2010 11:21 PM, Robert Story wrote: On Mon, 13 Dec 2010 11:16:54 -0500 Bill wrote: BF>I'm not sure what to suggest as a solution. For those who use BF>net-snmp as the

Re: Net-snmp 5.6 uses the wrong interface on a multi-homed box with asymmetric routing

2010-12-16 Thread Jan Safranek
On 12/15/2010 05:26 PM, Robert Story wrote: > JS> The problem is not to get this information, the real > JS> challenge is to do it effectively, i.e. cache them somewhere, refresh > JS> the cache sometimes, look up in the cache effectively, ... Or do we want > JS> to run netlink query on every o

Re: Net-snmp 5.6 uses the wrong interface on a multi-homed box with asymmetric routing

2010-12-15 Thread Jan Safranek
On 12/13/2010 11:21 PM, Robert Story wrote: > On Mon, 13 Dec 2010 11:16:54 -0500 Bill wrote: > BF> I'm not sure what to suggest as a solution. For those who use > BF> net-snmp as the agent on a router, where asymmetric routing like this > BF> is very common, this black hole for the responses is

CFV: reload ipv6IfTable data

2010-12-09 Thread Jan Safranek
Current implementation of ipv6IfTable never reloads list of interfaces, deleted or added interfaces never (dis-)appear from the table. This patch reloads the list of interfaces whenever the table is accessed. It adds also minor optimization (store last number of interfaces so realloc() probably

APSL 1.1 code in net-snmp

2010-08-03 Thread Jan Safranek
Hello, I've got some complaints that Net-SNMP contains code covered by Apple Public Source License 1.1 [1], namely it is trunk/agent/mibgroup/host/data_access/swrun_darwin.c (the license is in the middle of the file, not at the top). APSL 1.1 is considered 'bad' from Fedora point of view [2] (

Re: range_list is too small

2010-06-25 Thread Jan Safranek
On 06/24/2010 06:01 PM, Dave Shield wrote: > On 24 June 2010 15:19, Magnus Fromreide wrote: >>> I suspect that what is probably needed is some form of flag within the >>> range_list structure, to indicate whether the values should be treated as >>> signed or unsigned (with appropriate casts if nec

Re: range_list is too small

2010-06-24 Thread Jan Safranek
On 06/24/2010 11:06 AM, Dave Shield wrote: > Two comments. > Firstly, I would regard 'range_list' as an internal data structure, > rather than part of the public API, so it would be legitimate (IMO) > to tweak this as part of a new major release. > Hence it might be possible to make such a c

range_list is too small

2010-06-23 Thread Jan Safranek
I've stumbled upon struct range_list being too small for some MIBs. E.g. snmptranslate -Td NET-SNMP-AGENT-MIB::nsTransactionID: ... SYNTAX Unsigned32 (0..-1) Correct is (0..4294967295), but struct range_list uses signed int to store range boundaries and 4294967295 won't fit there. The fix is sim

util_funcs headers are not installed

2010-06-14 Thread Jan Safranek
Sometime before net-snmp-5.5 Magnus reorganized util_funcs.h and created new headers in agent/mibgroup/util_funcs/*.h. Old util_funcs.h just includes them, but these header files won't get installed on 'make install'. There is quite ugly hack to get mibgroup/util_funcs.h installed and I don't t

Porting SVN rev. 18030 to V5-5-branches

2010-05-14 Thread Jan Safranek
Hi Bart, I've noticed that my recent autoconf voodoo with lm_sensors detection does not work in 5.5 branch, because configure.d/config_os_headers is checked *after* configure.d/config_modules_lib. In the trunk you moved configure.d/config_os_headers before configure.d/config_modules_lib in SVN

Re: SF.net SVN: net-snmp:[18714]

2010-05-13 Thread Jan Safranek
On 05/13/2010 03:12 PM, Bart Van Assche wrote: > Hello Jan, > > This patch breaks the build on the 5.5 branch because it referes to a > non-existing macro NETSNMP_LOGONCE() . > > Bart. Ouch, sorry, I've just fixed it. Thanks for heads up! Jan -

Re: SF.net SVN: net-snmp:[18711] trunk/net-snmp/configure.d

2010-05-13 Thread Jan Safranek
On 05/13/2010 11:27 AM, Bart Van Assche wrote: > Hello Jan, > > Is there a particular reason why you have used AC_CHECK_DECLS() instead > of AC_CHECK_FUNC() ? Even if AC_CHECK_DECLS() finds the specified > declaration, linking can still fail. AC_CHECK_FUNC() verifies whether > linking succeeds. Th

Can't start snmpd as different user

2010-03-31 Thread Jan Safranek
Hi, I've stumbled upon a possible bug in net-snmp-5.5 in on Fedora 12: $ snmpd -f -Lo -u daemon initgroups failed: Operation not permitted Looking at strace and code in snmpd.c, I can see that the snmpd changed UID to daemon user, but subsequent initgroups() fails with EPERM. The cause is patch

Re: changing behavior of netsnmp_parse_args

2010-03-25 Thread Jan Safranek
On 03/24/2010 02:14 PM, Robert Story wrote: > On Wed, 24 Mar 2010 13:54:15 +0100 Jan wrote: > JS> > What is the intended interpretation of these three return values? > JS> > > JS> > -1 seems to indicate an invalid or unrecognised option value > JS> > -2 seems to indicate that process

Re: changing behavior of netsnmp_parse_args

2010-03-24 Thread Jan Safranek
On 03/24/2010 01:50 PM, Dave Shield wrote: > On 24 March 2010 11:10, Jan Safranek wrote: >> In trunk I've made following change to fix a bug: >> >> It adds new negative return value to netsnmp_parse_args and >> snmp_parse_args, which should be handled by callers

changing behavior of netsnmp_parse_args

2010-03-24 Thread Jan Safranek
In trunk I've made following change to fix a bug: On 03/24/2010 11:47 AM, jsafra...@users.sourceforge.net wrote: > Revision: 18358 >http://net-snmp.svn.sourceforge.net/net-snmp/?rev=18358&view=rev > Author: jsafranek > Date: 2010-03-24 10:47:21 + (Wed, 24 Mar 2010) > > Log Me

Re: CFV: Four new patches (was: Default AgentX target)

2010-03-24 Thread Jan Safranek
On 03/22/2010 04:54 PM, Dave Shield wrote: > 1) Latch disk statistics (disk-latch.patch) +1 both > 2) Missing privKey crash (des-priv.patch) +1 both > 3) VACM best match(vacm-best-match.patch) 0 > 4) MIB dir path logging (mibdir-log.patch) 0 Jan ---

Re: hrStorage looses track of remounted file system (bug #1689551)

2010-03-17 Thread Jan Safranek
On 03/15/2010 07:57 PM, Robert Story wrote: > On Sun, 14 Mar 2010 12:11:42 -0300 Leonardo wrote: > LC> > There is a patch in Red Hat Bugzilla: > LC> > https://bugzilla.redhat.com/show_bug.cgi?id=532672. It keeps track of > LC> > already used indexes and tries to read /etc/mtab in the same ord

Re: Processing invalid messages

2010-03-16 Thread Jan Safranek
On 03/05/2010 04:44 PM, Jan Safranek wrote: > Hi, > > I've stumbled upon snmpd processing malformed requests. How should > snmplib react to it? E.g. my snmpd received get-request with ASN.1 error > in Request ID - instead of Type: 2, Length: 1, Value: 0xc it received > T

Re: hrStorage looses track of remounted file system (bug #1689551)

2010-03-12 Thread Jan Safranek
On 03/05/2010 08:34 PM, Leonardo Chiquitto wrote: > On Tue, Mar 2, 2010 at 12:40 PM, Robert Story wrote: >> On Mon, 11 Jan 2010 12:29:56 -0200 Leonardo wrote: >> LC> Dave, I'm interested in using a part of your work on the new filesystem >> LC> MIB to fix the problem described in this bug. To av

Re: RPM API status

2010-03-11 Thread Jan Safranek
On 03/10/2010 08:22 PM, Robert Story wrote: > On Thu, 04 Mar 2010 09:54:47 -0500 Jeff wrote: > JJ> On Mar 4, 2010, at 9:16 AM, Jan Safranek wrote: > JJ> > in all supported branches there should be check in ./configure script, > JJ> > which enables legacy RPM API

Processing invalid messages

2010-03-05 Thread Jan Safranek
Hi, I've stumbled upon snmpd processing malformed requests. How should snmplib react to it? E.g. my snmpd received get-request with ASN.1 error in Request ID - instead of Type: 2, Length: 1, Value: 0xc it received Type: 32, which is wrong. But the request got processed and answered, nothing ch

RPM API status

2010-03-04 Thread Jan Safranek
Hi, in all supported branches there should be check in ./configure script, which enables legacy RPM API when the user has newer RPM (4.6 and later). Today I wanted to port the new host/hrSWInstalled table to the new RPM API in SVN trunk, but I was surprised it's already done. Thanks to Dave Sh

Re: Autoconf version

2010-03-03 Thread Jan Safranek
On 02/23/2010 03:32 PM, Robert Story wrote: > On Tue, 23 Feb 2010 13:28:05 +0100 Jan wrote: > JS> Do we have any policy which autoconf/autoheader to use? I've noticed > JS> autoconf-2.59 was the last used in the 5.2 branch and I have installed > JS> autoconf-2.63 (Fedora 12). > > Fedora should h

Autoconf version

2010-02-23 Thread Jan Safranek
Hi, I'm working on compilation with new rpm-4.6 (see SVN rev. 18193). I've added some checks to e.g. V5-2-patches/net-snmp/configure.in and now I need to generate new configure script. Do we have any policy which autoconf/autoheader to use? I've noticed autoconf-2.59 was the last used in the 5

Purpose of --enable-as-needed

2010-01-12 Thread Jan Safranek
Hi, configure script says that there is --disable-as-needed option. I've looked into the configure script and it looks like it does nothing regarding this option. Should it enable/disable something like "-Wl,--as-needed"? Or what is this option good for? It seems to me it has no effect on resu

Fix sending of responses to multicast/broadcast packets.

2009-09-24 Thread Jan Safranek
If snmpd receives a broadcast request, it stores it's destination (i.e. the broadcast address) and tries to send the response with the same source address. sendmsg() does not like broadcast addresses there and returns error + response is not sent, which makes some users sad. I have no idea, why the

Re: [PATCH] RFC: rename MIB to NETSNMP_MIB2_OID

2009-09-02 Thread Jan Safranek
On 09/01/2009 10:54 PM, Wes Hardaker wrote: >>>>>> On Tue, 01 Sep 2009 00:28:59 +0200, Thomas >>>>>> Anders said: > > TA> Jan Safranek wrote: >>> sure, here is second version of the patch, now with >>> NETSNMP_NO_LEGACY_DEFINITI

RE: [PATCH] RFC: rename MIB to NETSNMP_MIB2_OID

2009-08-31 Thread Jan Safranek
On 08/28/2009 11:59 PM, Thomas Anders wrote: > At the very least, NETSNMP_NO_LEGACY_DEFINITIONS is used at quite a few > places already for exactly the same purpose as discussed here. > I don't think it's the best time to introduce something that's inconsistent > with the current approach that late

Re: [PATCH] RFC: rename MIB to NETSNMP_MIB2_OID

2009-08-28 Thread Jan Safranek
Ah, and I forgot to mention: NETSNMP_COMPAT_5_4 should be written somewhere, where application developers and package monkeys like me know that it exists... But where? Jan -- Let Crystal Reports handle the reporting - F

[PATCH] RFC: rename MIB to NETSNMP_MIB2_OID

2009-08-28 Thread Jan Safranek
below, apcupsd compiles successfully. I don't think that suggested NETSNMP_NO_LEGACY_DEFINITIONS is good idea - the application would see the old identifiers by default. IMHO it is better to advertise the new ones and show the old only if application (or its packager) explicitly ask so. Signed-

apcupsd and net-snmp-5.5.

2009-08-27 Thread Jan Safranek
Hi, as preparation to move to net-snmp-5.5 in Fedora I have tried to recompile all packages which depends on it with net-snmp-5.5.rc2. Most of them compiled successfully, but I have found some packages that failed because of changes in public headers. New include/net-snmp/library/snmp_client.h

[PATCH] Fix C++ guard in library/types.h

2009-08-26 Thread Jan Safranek
ction declared in the header file, but I noticed it's common practice here. Please note I explicitly did not fix coding style of the file, I think it should be separated from this fix. Let me know if I shall tidy up the whitespaces. Signed-off-by: Jan Safranek --- net-snmp/include/net-sn

Re: [PATCH] Fix potential endless loop in ipDefaultRouterTable

2009-08-25 Thread Jan Safranek
On 08/25/2009 07:46 PM, Thomas Anders wrote: > Jan Safranek wrote: >> This patch advances to the next route from netlink if CONTAINER_INSERT >> fails. > > +1 > > Has the patch been tested on a system with and/or without the (former) loop > problem? Sure, tested on

[PATCH] Fix potential endless loop in ipDefaultRouterTable

2009-08-25 Thread Jan Safranek
_INSERT in defaultrouter_linux.c:299 may fail. The loop then does not advance to next route, but continues with the already processed route instead and CONTAINER_INSERT fails again and the same route is processed again and again. This patch advances to the next route from netlink if CONTAINER_INSERT fails. Signed-o

Re: UDPv6/TCPv6 tests on RedHat

2009-08-14 Thread Jan Safranek
On 08/13/2009 08:02 PM, Thomas Anders wrote: > The new UDPv6/TCPv6 transport tests (62, 63) in SVN trunk (5.5.rc1) fail for > me on older RedHat machines, namely: > >Redhat Linux 7.1 (kernel 2.4.20) >Redhat Linux 9 (2.4.20) >RHEL 2.1/x86 (2.4.9) >RHEL 3/x86 (2.4.21) >RHEL 3/amd

MIB that must run as root user

2009-04-20 Thread Jan Safranek
In our patch tracker we have patch #2103492, which adds new MIB. The MIB implementation must run as root - it needs superuser privileges to perform some ioctl magic. Are such MIBs allowed to be accepted into SVN? Or how should we handle such patches? Jan ---

Re: patch 1927751 broke build on Linux?

2009-03-31 Thread Jan Safranek
Magnus Fromreide wrote: > On Mon, 2009-03-30 at 13:50 +0200, Jan Safranek wrote: >> Maybe plain #ifdef checks in icmp.c would be more readable, the MLD_ >> macros are used only there... > > I think you are right - #ifdef checks in icmp.c is more readable and > keeps t

Re: patch 1927751 broke build on Linux?

2009-03-30 Thread Jan Safranek
y there... Jan commit 9d7948a7a6bf9fe3e1c3b92547064a985a4ab1a0 Author: Jan Safranek Date: Mon Mar 30 11:57:38 2009 +0200 Add configure checks for MLD_ style ICMPv6 message type definitions. Fall back to ICMP6_ definitions and redefine them to MLD_, if they are available. diff

Re: Exit status on bind error

2008-12-04 Thread Jan Safranek
Wes Hardaker wrote: >>>>>> On Tue, 11 Nov 2008 15:43:24 +0100, Jan Safranek <[EMAIL PROTECTED]> >>>>>> said: > > JS> I looked into the sources and I can see that the agent is deamonized > JS> before the listening sockets are created. Is

Re: Fedora 10+x86_64+snmpd gives segfault in libc-2.9.so at startup

2008-12-04 Thread Jan Safranek
Jan Houtsma wrote: > Hi, > > Other reports are already getting in. It's only related to x86_64 > systems. Apparently new releases > are only tested on i386? Because this segfault is so obvious on x86_64 > and happens as soon as > you start the daemon with default config. As Fedora maintainer of n

Storage size consolidation

2008-11-26 Thread Jan Safranek
Hello, there are few bugs in our sf.net bug tracker that complain about big disks and values reported by net-snmp agent. See items 2340904, 2340840, 1743171, 1445722 and 1523452. It's also tracked as 5.4.2 open item on our Wiki. There are basically two problematic areas: HOST-RESOURCES-MIB:

Exit status on bind error

2008-11-11 Thread Jan Safranek
Hello, when the snmpd fails to bind listening port, it writes 'Error opening specified endpoint "udp:0.0.0.0:162", Server Exiting with code 1' to syslog and dies, but its exit code it 0. I looked into the sources and I can see that the agent is deamonized before the listening sockets are creat

Re: Is it possible to set the L3 source interface IP address in a trap packet?

2008-09-18 Thread Jan Safranek
Zhouhuai Shen wrote: > Hi Jan, > > I checked the patch for 'v1trapaddress', it used the following to > register the v1trapaddress string in the snmpd.conf: > > netsnmp_ds_register_config(ASN_OCTET_STR, app, "v1trapaddress", > NETSNMP_DS_APPLICATION_ID, NETSNMP_DS_AGENT_TRAP_ADDR); > > Once the

Re: Is it possible to set the L3 source interface IP address in a trap packet?

2008-08-27 Thread Jan Safranek
Zhouhuai Shen wrote: > Hi Jan, > > Thanks a lot for the patch. It fixed the agent address inside the UDP > payload. > > The '[snmp] clientaddr 192.168.1.1' in my snmpd.conf doesn't fix > the IP address in the UDP packet in my case. For example, the > outgoing interface IP for the trap is 172.

Re: Is it possible to set the L3 source interface IP address in a trap packet?

2008-08-18 Thread Jan Safranek
Zhouhuai Shen wrote: > Hi Jan, > > Thanks a lot for your help. > > I have put the '[snmp] clientaddr' option to set source address of UDP > packet with the trap as in the following in my snmpd.conf file: > > [snmp] > clientaddr 192.168.1.1 > [snmpd] > .(The rest of commands in my snmpd.conf

Re: Is it possible to set the L3 source interface IP address in a trap packet?

2008-08-15 Thread Jan Safranek
Zhouhuai Shen wrote: > Hi all, > > Is it possible to set the layer 3 source IP address for a trap packet to > a certain interface on the device, other than the outgoing interface? > > I have tried to set the member localname of the netsnmp_session data > structure to the desired interface addre

Re: Configuring NETSNMP_TEMP_FILE_PATTERN

2008-07-24 Thread Jan Safranek
Thomas Anders wrote: > Jan Safranek wrote: >> I've already tried this, but snmptrapd still creates files in /tmp. And >> if I patch the net-snmp-config.h.in manually, it creates it wherever I >> want. >> >> There should be some #ifndef NETSNMP_TEMP_FILE_PATTER

Re: Configuring NETSNMP_TEMP_FILE_PATTERN

2008-07-23 Thread Jan Safranek
Thomas Anders wrote: > Jan Safranek schrieb: >> Is there any way, how to modify NETSNMP_TEMP_FILE_PATTERN without >> patching net-snmp-config.h.in? Like some well-hidden argument to >> ./configure or so? I don't like snmptrapd putting files into /tmp >> (res

Configuring NETSNMP_TEMP_FILE_PATTERN

2008-07-23 Thread Jan Safranek
Is there any way, how to modify NETSNMP_TEMP_FILE_PATTERN without patching net-snmp-config.h.in? Like some well-hidden argument to ./configure or so? I don't like snmptrapd putting files into /tmp (resp. SELinux does not like it, see http://danwalsh.livejournal.com/11467.html). Jan -

Re: Changes in our .spec file

2008-06-12 Thread Jan Safranek
Thomas Anders wrote: Jan Safranek wrote: - we want one big package + separate -perl and -devel, as it is now, + proper Conflicts: and Provides:, tailored to as many distributions as we can. That means somebody (I volunteer for RHEL and Fedora) will check current .spec in SVN, add proper

Re: Asynchronous write

2008-05-15 Thread Jan Safranek
Magnus Fromreide wrote: > Do the rewrite affect both stream and packet sockets or only stream > sockets? Currently both, but if there will be flag allowing asynchronous write, like hardaker is suggesting, I'll have to rewrite it either. > What action should be taken if the remote party fails to

Asynchronous write

2008-05-14 Thread Jan Safranek
Hi, net-snmp by default expects that send() on a socket always send whole provided buffer and is blocking. This leads to deadlocks under heavy load - see bug #1598344. I'm rewriting the snmp_api so the write will be asynchronous and non-blocking. It seems to me that the session API is somehow

Re: Changes in our .spec file

2008-05-12 Thread Jan Safranek
Thomas Anders wrote: > My initial list of distros that *I* am sort-of-supporting (i.e. provide > packages for via the openSuSE Build Service) is here: > > http://www.net-snmp.org/wiki/index.php/Third-Party_Packages During the monthly administrative meeting we agreed: - the [above] list looks

Changes in our .spec file

2008-05-06 Thread Jan Safranek
Hi, during discussion with Thomas Anders about the .spec file in SVN we found out few possible improvements, which need more discussion on this list. Fedora splits Net-SNMP to many subpackages - net-snmp (the server), net-snmp-utils (the clients), net-snmp-libs, net-snmp-perl, net-snmp-devel

Third party packages + Fedora or Red Hat Enterprise Linux

2008-04-23 Thread Jan Safranek
Hi, I have tested the "Third party packages" from openSUSE build service, managed by tanders and darix, together with our 'native' php-snmp package. The test includes start of snmpd daemon and simple snmpget() call in php code, just to check the rpm dependencies are satisfied and dynamic linki

How to write successful patches

2008-01-15 Thread Jan Safranek
Hello, It's my job to maintain net-snmp in Red Hat Enterprise Linux and Fedora distributions. During this work I fix problems reported by users and I always try to send my bug fixes and extensions to Net-SNMP patch tracker. But I am quite disappointed that most of these patches were not accept

Re: Has anybody tried compiling with sensors using lm-sensors 3.0.0?

2007-11-12 Thread Jan Safranek
Dave Shield wrote: > On 12/11/2007, Jan Safranek <[EMAIL PROTECTED]> wrote: >> The library has slightly different interface. Current net-snmp as it is >> in SVN does not compile with lm-sensors 3.0.0-rc3. I am trying to fix >> ucd-snmp/lmSensors.c to reflect the chang

Re: Has anybody tried compiling with sensors using lm-sensors 3.0.0?

2007-11-12 Thread Jan Safranek
Bruce Shaw wrote: > lm-sensors 3.0.0-rc1 has been released! > > http://lists.lm-sensors.org/pipermail/lm-sensors/2007-September/021277.h > tml > > The release notes: > > * Pretty much all functions of the old API are gone or work > differently. > ... > > Can anybody figure out what they've c