Hello,

Ok I was on the right path. Basically I completely forgot the little trick I
did.

This is what confused me. I have two configuration files both called
snmpd.conf.
One is for persistence and one is for general configuration which is
produced using snmpconf -g basic_setup.
My SNMPCONFPATH was set to the point general at /usr/var/local/share. The
persistence configuration resides in /var/net-snmp.

I was manually inserting my token into the persistence file. Thinking that
it would be
read and my callback function would be called. Idiot, total idiot. The
callback function would only be called if the token resided in the
snmpd.conf file pointed to...yes you get it SNMPCONFPATH.
At some point I must of altered this environment variable to point to
/var/net-snmp and pick up the tokens.

The reason why I am doing this. Basically when the agent restarts I want to
pull the tokens from the persistence and re-create the oids.

The question begs. The SNMPCONFPATH points to the general agent
configuration. Should there be two configuration files?
I think there should just be one right?

Thanks,
Garyc

----- Original Message -----
From: "Gary Clark" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, August 28, 2004 11:39 AM
Subject: Being persistent with persistence


> Hello,
>
> Ok I messed up somewhere. Just dont know where. I think its an environment
> variable issue?
> I have been using persistence. Extracting tokens and creating oids in my
MIB
> tree and all is well.
> Then I did something which has caused my environment to change. I cannot
get
> persistence to load again.
>
> Here is what I am doing:
>
> ./configure --with-mib-modules=psb_test
> make
>
> Everything builds fine and I can perform set and get requests on the oid.
I
> register the app handler
> and create a function that should be called.
>
> snmpd_register_config_handler("myFredToken",parse_func,NULL,NULL);
>
>
> I manully modify the /var/snmpd.conf to contain:
>
> myfredToken 1
>
> I dont see my parse function being called. I enabled trace and saw that
the
> token is getting registered however no callback is made.
> This is probably going to be blatently obvious to the net-snmp gurus,
myself
> a humble novice has been stumped.
>
> However I think its my configuration environment. Likely SNMPCONFPATH
> environment variable?
>
> I use snmpconf -g basic_setup. This produces the snmpd.conf configuration.
I
> point the SNMPCONFPATH to /usr/local/share/snmp?
>
> Is this OK.
>
> If anybody can shed some light on this blind fellow much appreciated and
> promise to return help if I can.
>
> Cheers,
> Garyc
>
>
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by BEA Weblogic Workshop
> FREE Java Enterprise J2EE developer tools!
> Get your free copy of BEA WebLogic Workshop 8.1 today.
> http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
> _______________________________________________
> Net-snmp-users mailing list
> [EMAIL PROTECTED]
> Please see the following page to unsubscribe or change other options:
> https://lists.sourceforge.net/lists/listinfo/net-snmp-users



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
_______________________________________________
Net-snmp-users mailing list
[EMAIL PROTECTED]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to