Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: snmp-target

5 views
Skip to first unread message

Dave Shield

unread,
Apr 6, 2012, 11:51:12 AM4/6/12
to
On 4 April 2012 11:52, MANSOUR NASERI <man_n...@yahoo.com> wrote:
> I want to changed or add trap destination address remotely from manager.
> and I read docs: snmpd notification filtering - Net-SNMP Wiki and SNMP
> notification processing - Net-SNMP Wiki.
> but after writing that tables nothing happened.

What exactly did you write into these tables?
What SET commands did you use, and what do you see if you walk these tables?

It's a little difficult to help you, if we've no idea about what
you've actually done. "writing the tables" is somewhat vague!

Dave

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
Net-snmp-users mailing list
Net-snm...@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Dave Shield

unread,
Apr 7, 2012, 5:20:21 PM4/7/12
to
[ First - *please* don't mail me privately, without copying
any responses to the mailing list. I don't have the time
or inclination to offer private, unpaid, SNMP consultancy.
Keep discussions to the list, where others can both learn
and offer advice. Thanks. ]

On 7 April 2012 07:00, MANSOUR NASERI <man_n...@yahoo.com> wrote:
> Thanks for your kindness reply.
>
> I am using MG-soft MIB browser for adding new rows like this sequence:
> Step1 : First of all as the document says
> Get   snmpTargetSpinLock valule it return 0
> Step2:    then Set snmpTargetSpinLock to 0 again
> Step3:    Get  snmpTargetSpinLock , it return 1(for test)
> Step4:    from  snmpV2 | snmpModules |
> snmpTargetMIB | snmpTargetObjects | snmpTargetAddrTable |
> snmpTargetAddrEntry:
>     set snmpTargetAddrRowStatus to 5 for instants’ 51
>     (1.3.6.1.6.3.12.1.2.1.9.51 set to 5)
>     it causes create new row like this:
> Instance  snmpTargetAddrName(IDX, IMP)  snmpTargetAddrTDomain
> snmpTargetAddrTAddress  snmpTargetAddrTimeout  snmpTargetAddrRetryCount
> snmpTargetAddrTagList  snmpTargetAddrParams  snmpTargetAddrStorageType
> snmpTargetAddrRowStatus
> --------- ----------------------------- ----------------------
> ----------------------- ---------------------- -------------------------
> ---------------------- --------------------- --------------------------
> ------------------------
> 51        Not accessible                Not available          Not
> available           1500                   3
> (zero-length)          Not available         nonVolatile(3)
> notReady(3)
>
> I think    snmpTargetAddrName shoud not be” Not accessible”


No - snmpTargetAddrName is the index of the snmpTargetAddrTable,
so it should indeed be "not-accessible"
You have created a row with a snmpTargetAddrName value of "3"
(the character with ASCII value 51) so this value is present in every
OID returned from this table. There's no need for this object to be
directly accessible as well.
See the MIB definition for confirmation.


>
> Step5:    on the table with  instance 51 write other column like this:
>
> Set snmpTargetAddrTDomain 51 to   1.3.6.1.6.1.1
> set snmpTargetAddrTAddress 51 to C0A80005 (hex of 192.168.0.5)

That's not a valid UDP Domain address.
You've specified the IP address, but omitted the UDP port.

The most natural value would probably be C0A8000500A2
(port 162 on 192.168.0.5)
See SNMPv2-TM::SnmpUDPAddress for details.


> set snmpTargetAddrTimeout 51 to 100
> set snmpTargetAddrRetryCount 51 to 3
> set snmpTargetAddrTagList 51 to Manager1
> set snmpTargetAddrParams 51 to  snmpv2

This identifies an entry in the snmpTargetParamsTable
(See the definition of SNMP-TARGET-MIB::snmpTargetAddrParams)

What values have you set in this table, for the row with
index value "snmpv2" ?


> snmpTargetAddrStorageType 51 to 1
>
> Step6:      snmpTargetAddrRowStatus 51 to 1
>
> The row is:
> Instance  snmpTargetAddrName(IDX, IMP)  snmpTargetAddrTDomain
> snmpTargetAddrTAddress  snmpTargetAddrTimeout  snmpTargetAddrRetryCount
> snmpTargetAddrTagList  snmpTargetAddrParams  snmpTargetAddrStorageType
> snmpTargetAddrRowStatus
> --------- ----------------------------- ----------------------
> ----------------------- ---------------------- -------------------------
> ---------------------- --------------------- --------------------------
> ------------------------
> 51        Not accessible                snmpUDPDomain
> C0A80005                100                    3
> Manager1               snmpv2                other(1)
> active(1)
>
>
> Step7:    On the snmpNotifyTable write columns like this:
>     Set snmpNotifyRowStatus 51 to  5
>     Set snmpNotifyTag 51 to  Manager1
>     Set snmpNotifyStorageType 51 to 3
>     Set snmpNotifyRowStatus 51 to 1

snmpNotifyTag is the index value for the entry in the
snmpTargetAddrTable to use (see the MIB definition)
You have set this to "Manager1"
What settings have you configured in the snmpTargetAddrTable
for this index value?


>
>
> Instance  snmpNotifyName(IDX, IMP)  snmpNotifyTag  snmpNotifyType
> snmpNotifyStorageType  snmpNotifyRowStatus
> --------- ------------------------- -------------- ---------------
> ---------------------- --------------------
> 51         Not accessible            Manager1       trap(1)
> nonVolatile(3)         active(1)
0 new messages