so i just discovered it was possible to run remote scripts using snmp.
problem is, one can't pass arguments to the remote script from the client machine.
for instance, the code below will execute the script called CallDropper on sgt66.blahblah.com.
snmpwalk -v2c -c A@GTF42 sgt66.blahblah.com NET-SNMP-EXTEND-MIB::nsExtendOutputFull.\"CallDropper\"
But what if I want to pass a couple of arguments to CallDropper? Is there a way to do this?
I've stayed away from this - SNMP is a VERY complex protocol. Here is the way you start doing it. It involves creating C code and working with the Netsnmp library. It is not just like bash or ksh. OID's (from MIB's) are involved.
Net-SNMP
As far as I can see from the MIB definition, you should use the nsExtendArgs object;
nsExtendArgs OBJECT-TYPE
SYNTAX DisplayString
MAX-ACCESS read-create
STATUS current
DESCRIPTION
"Any command-line arguments for the command"
DEFVAL { ''H } -- the empty string
::= { nsExtendConfigEntry 3 }
Cheers, Lo�c