nv-l
[Top] [All Lists]

Re: Passing trap data to script in action node in rule.

To: nv-l@lists.tivoli.com
Subject: Re: Passing trap data to script in action node in rule.
From: "Gavin Newman" <NEWMANGJ@banksa.com.au>
Date: Tue, 01 Aug 2000 13:58:24 +0930
James

The problem turned out to be that the variables are multi-word and I was not 
enclosing the var names in quotes in the action node in the rule. Consequently 
when they got to the script and were used as vars $1, $2 etc I was getting each 
word of the first few variables passed by the rule in each of the receiving 
variables and ran out of receiving variables before I even got the NVATTR_3. 
Enclosing each var in quotes in the rule fixed things.

Thanks for clarifying the variables though.

Cheers - Gavin

>>> <James_Shanks@tivoli.com> 31/07/2000 21:48:41 >>>


You've confused me.  What stuff are you trying to get exactly?

The third NetView trap variable contains the exact display text for Node Up and
Node Down events, unless you have changed trapd.conf to display something else,
so $NVATTR_3 should give you that.  If you have changed it, then you will have
to re-construct that in your script.  In other words, if you changed trapd.conf
to display "Holy smokes, batman, we have a $3"  then you action script is only
going to get the value of  that third variable in "$NVATTR_3" and you would have
to add the additional text yourself.  Is that the question you are asking?

James Shanks
Team Leader, Level 3 Support
 Tivoli NetView for UNIX and NT


_________________________________________________________________________
NV-L List information and Archives: http://www.tkg.com/nv-l



**********************************************************************
   *****   IMPORTANT INFORMATION    *****
This document should be read only by those persons to whom
it is addressed and its content is not intended for use by
any other persons. If you have received this message in
error, please notify us immediately. Please also destroy and
delete the message from your computer. Any unauthorised form
of reproduction of this message is strictly prohibited.
Bank SA is not liable for the proper and complete transmission
of the information contained in this communication, nor for any


<Prev in Thread] Current Thread [Next in Thread>

Archive operated by Skills 1st Ltd

See also: The NetView Web