Yes, and the substituted characters can be restored too, but are a little
trickier because anything Netview doesn't like gets converted to
underscores. I have variables with commas that get converted to
underscores, so you have to be careful.
Regards,
Bill Kellam
Enterprise Integration and Management
"Qureshi, Fawad"
<Fawad.Qureshi@ss
a.gov> To
Sent by: "'nv-l@lists.us.ibm.com'"
owner-nv-l@lists. <nv-l@lists.us.ibm.com>
us.ibm.com cc
Subject
12/01/2003 10:41 RE: [nv-l] Netview ruleset question
AM
Please respond to
nv-l@lists.us.ibm
.com
Pritesh,
Netview adds \ for security reasons. You can drop them in Perl with
following line:
$NVATTR_3 =~ s/\\\//g;
Cheers
Fawad Qureshi
Division of Network Engineering - SSA / RSIS
410-965-4413
-----Original Message-----
From: owner-nv-l@lists.us.ibm.com
[mailto:owner-nv-l@lists.us.ibm.com] On Behalf Of Pritesh Jewan
Sent: Monday, December 01, 2003 9:25 AM
To: nv-l@lists.us.ibm.com
Subject: [nv-l] Netview ruleset question
Hi List,
Environment: Netview V7.1.4 on Redhat Advanced Server2.1
I am trying to pass trap variables in the action node of my ruleset
to an external script(the script is a perl script). I call the script
using the action node and <full path>scriptname "$NVE" "$NVA" "$NVT"
"$NVATTR_1" "$NVATTR_2" "$NVATTR_3". When I print out the variables
passed to the script I noticed that some of the variables have been
slightly modified. As an example if I get an event for an ATM
interface that has gone down, the event appears correctly in the
event desk(Interface ATM2/0.100-aal5 down) but when my script prints
this variable out to a file it is as follows:
ATM2_0\.100\-aal5 down
I was hoping to use the interface information to get certain mib
variables before doing a wpostzmsg to tec. But the slight
modifications to the variables is causing problems as I can't
correlate the modified variable above with data I get back from the
devices using snmpget's. I tried echo'ing the variables in a shell
script (thinking it might be perl causing the problem) but the same
thing happens. If I look at the nvaction.alog they also appear
"incorrectly" in this trace file. The following is a few lines of the
trace file:
2003/01/12 13:38:40 : 44 :perl /usr/OV/custom/scripts/test.pl "$NVE"
"$NVA" "$NVATTR_1"~2003/01/12 13:40:45~1.3.6.1.4.1.2.6.3.1
~6~58916867~346663104~1010692~public~2~regent-iol-elp.impol.local~Interface
ATM2/0.100-aal5 down.~172.20.247.17 1070278845 775
1175~openview~regent-iol-elp.impol.local:ATM2/0.100-aal5~172.20.247.17
~1175~3~N~3
2003/01/12 13:40:45 ./nl_Actionsvr.C[822] : Varbind contained an
illegal character.
Issuing sanitized version of the varbind:
2003/01/12 13:40:45 ./nl_Actionsvr.C[823] :
NVATTR_2="regent\-iol\-elp\.impol\.local"
2003/01/12 13:40:45 ./nl_Actionsvr.C[822] : Varbind contained an
illegal character.
Issuing sanitized version of the varbind:
2003/01/12 13:40:45 ./nl_Actionsvr.C[823] : NVATTR_3="Interface
ATM2_0\.100\-aal5 down\."
2003/01/12 13:40:45 ./nl_Actionsvr.C[822] : Varbind contained an
illegal character.
Issuing sanitized version of the varbind:
2003/01/12 13:40:45 ./nl_Actionsvr.C[823] :
NVATTR_4="172\.20\.247\.17 1070278845 775 1175"
2003/01/12 13:40:45 ./nl_Actionsvr.C[822] : Varbind contained an
illegal character.
Issuing sanitized version of the varbind:
2003/01/12 13:40:45 ./nl_Actionsvr.C[823] :
NVATTR_6="regent\-iol\-elp\.impol\.local_ATM2_0\.100\-aal5"
2003/01/12 13:40:45 ./nl_Actionsvr.C[822] : Varbind contained an
illegal character.
Issuing sanitized version of the varbind:
2003/01/12 13:40:45 ./nl_Actionsvr.C[823] :
NVATTR_7="172\.20\.247\.17"
2003/01/12 13:40:45 : 44 command successful. output data is:
1.3.6.1.4.1.2.6.3.1tivnetview.impol.local2
What do the "Varbind contained an illegal character" messages mean?
Has anyone else had this problem?
Any suggestions/ideas would be greatly appreciated.
Regards
Pritesh
|