SNMP4J Command-Line Tool, version
...
3.4.0
Type
Code Block |
---|
java -SNMP4J-CLT.jar help <command> |
...
No Format |
---|
create-snapshot: create-snapshot <file> <address> <OID> defaults: defaults <action> list reset save dump-snapshot: dump-snapshot <file> example: example <command> get: get <address> <OID> [..] getbulk: [-Cr <repeaters>] [-Cn <non-repeaters>] getbulk <address> <OID> [..] getnext: getnext <address> <OID> [..] help: help [command]|all inform: inform <address> <OID>={<type>}<value> [..] license: license listen: listen <address> mib: mib <action> [<mib>] add <mib-file> del <mib-module-name> list oid: oid [find|find-by-descr] <regex> find oid find <regex> find-by-descr oid find-by-descr <regex> set: set <address> <OID>={<type>}<value> [..] smi: smi <OID> [..] table: table <address> <OID> [..] trap: [-To <notificationID>] trap <address> <OID>={<type>}<value> [..] usmKeyusmDHKey: usmKey auth|priv|authPriv <address> <old><oldpwd> <new><newpwd> [<user>] auth usmKeyusmDHKey auth <address> <old> <new> [<user>] priv usmKeyusmDHKey priv <address> <old> <new> [<user>] authPriv usmKeyusmDHKey authPriv <address> <old> <new> [<user>] usmUserusmDHKickstartInit: usmDHKickstartInit usmUser create|delete-privateKeysFile <dhKickstartPrivKeys.properties> <address> [<user> [<cloneFromUser> [<cloneFromEngineID>]]..] usmDHKickstartRun: createusmDHKickstartRun [-CE <usmUserEngineID>] [-createAndWait] usmUser createprivateKeysFile <dhKickstartPrivKeys.properties> <address> [<user> [<cloneFromUser> [<cloneFromEngineID>]]..] usmKey: delete [-CE <usmUserEngineID>] usmUser delete <address> <user> v1trap: -Te eid -Ts sid -Tg gid -Ta addr v1trap <address> <OID>={<type>}<value> [..] version: version walk: walk <address> <OID> OPTIONS: -A authPassphrase Set the authentication pass phrase for authenticated SNMPv3 messages. -CBusmKey auth|priv|authPriv <address> <old> <new> [<user>] auth usmKey auth <address> <old> <new> [<user>] priv usmKey priv <address> <old> <new> [<user>] authPriv usmKey authPriv <address> <oldpwd> <newpwd> [<user>] usmUser: usmUser create|delete <address> <user> [<cloneFromUser> [<cloneFromEngineID>]] create [-CE <usmUserEngineID>] [-createAndWait] usmUser create <address> <user> [<cloneFromUser> [<cloneFromEngineID>]] delete [-CE <usmUserEngineID>] usmUser delete <address> <user> v1trap: -Te eid -Ts sid -Tg gid -Ta addr v1trap <address> <OID>={<type>}<value> [..] version: version walk: walk <address> <OID> xml: xml <output-dir> OPTIONS: -A authPassphrase Set the authentication pass phrase for authenticated SNMPv3 messages. -CB Display brief column headers. Common prefixes will be dropped. -CE usmUserTableEngineID Set usmUserTableEngineID to be used as part of the index of the usmUserTable. Default is to use the authoritative engine ID (set via -e or probed) as the usmUserTableEngineID. -CH Do not display column headers. -Cb bufferSize The number of table rows to buffer before computing column sizes. -Cc columnWidth Print table columns with specified character width. -Cf columnSeparator Separate table columns with the specified separator string. The table is printed in compact form. By default columns are separated by spaces and aligned. -Ch Display only column headers. -Ci Prepend the index for each printed row. -Cil lowerBoundIndex Set the lower bound index for TABLE operations. -Ciu upperBoundIndex Set the upper bound index for TABLE operations. -Cl Left justify all cells when printing a table. -Cn non-repeaters Set the non-repeaters field for GETBULK PDUs. It specifies the number of supplied variables that should not be iterated over. The default is 0. -Cr max-repetitions Set the max-repetitions field for GETBULK PDUs. Display brief columnThis headers.specifies Commonthe prefixesmaximum willnumber of iterations be dropped. over the repeating -CEvariables. The default usmUserTableEngineIDis Set10. usmUserTableEngineID to be used-Cw as part of Specify the line width when printing tables the index of the usmUserTable. Default is to use-Djavax.net.ssl.keyStore keyStoreFile The key store file with SSL keys for the authoritativeTLS engineprotocol. ID (set via -e or probed) Djavax.net.ssl.keyStorePassword keyStorePassword The password for the key store file as the usmUserTableEngineIDwith SSL keys for TLS. -CH Djavax.net.ssl.trustStore keyStoreFile The trust store file with trusted Do not display column headers. -Cb bufferSize(public) SSL keys for the TLS protocol. The number of table rows to buffer before computing -Djavax.net.ssl.trustStorePassword keyStorePassword The password for the trust columnstore sizesfile. -CcDn columnWidth Print table columns with specified character width. -Cf Do not columnSeparatoruse any default Separateoption tablevalues columnsstored with the specified separatorin stringconfig. The table is printed-E in compact form. BycontextEngineID Set the context engine ID used for the SNMPv3 default columns are separated by spaces and scoped PDU. The authoritative engine ID will be aligned. -Ch used for the context engine ID, if Displaythe onlylatter columnis headers. -Ci Prepend the index for each printed rownot specified. -CilL lowerBoundIndex license Setkey the lower bound index for TABLE operations. Specify license and associated -Ciukey. The upperBoundIndex Set the upper bound index for TABLE operations. license -Cl Left justifyinfo allwill cellsbe whensaved printingin a table. -Cnthe SNMP4J-CLT config file in non-repeaters Set the non-repeaters field for GETBULK PDUs. It your home directory. Enter each license part specifies the number of supplied variables that enclosed in quotes, for example by '-L "b6 80 4d 68 should not be iterated over. The default is 0. -Cr max-repetitions Set the max-repetitions field3a for8 GETBULKc0 PDUs. f4" "O?fWO-3s"' -M mibRepositoryPath Set the path to the MIB repository to be used to This specifies the maximum number of iterations resolve object names (OIDs) and parse/format object over the repeating variables. The default is 10. -Cw values ('repository' is the default). The Specify the line width when printing tables -Djavax.net.ssl.keyStore keyStoreFile The key store file with SSL keys for repository directory must contain compiled MIB the TLS protocol. -Djavax.net.ssl.keyStorePassword keyStorePassword Themodules passwordfiles foronly. the key -Oesc escapeCharacter Escape character used in non-printable OCTET-STRING store file with SSL keys for TLS. -Djavax.net.ssl.trustStore keyStoreFile The trust store file with trustedvalues to print them as strings (instead of (public) SSL keys for the TLS protocol.hex-strings). Default is '_' and 'x' disables -Djavax.net.ssl.trustStorePassword keyStorePassword The password for the escaping and enables hex-string output. -Ors maxSizeRespPDU trustThe storemaximum file. size of the response -DnPDU in bytes. -OtCSV Do not use anyFor defaulteach optionSNMP valuesrow storedreceived inexactly one row of comma config. separated -Evalues will printed to contextEngineIDthe console where Set the context engine ID used for the SNMPv3 the first column contains the row index. scoped PDU.-Otd The authoritative engine ID will be Activates dense table operation mode which improves used for the context engine ID, if the latter is table retrieval performance on regular (dense) not specified. -L license key tables. This Specifyoption licensemust andnot associatedbe key.used Thewith licensesparse infotables. will be saved in-OttCSV the SNMP4J-CLT config file in Same as -OtCSV except that each row's first column your home directory. Enter each license part will report the current time (millis after enclosed in quotes, for example by '-L "b6 80 4d 68 1.1.1970) when the request has been sent. -Ta agentAddress 3a 8 c0Set f4" "O?fWO-3s"' -M mibRepositoryPath Set the path to the MIB repository to be used to the agent address field of a V1TRAP PDU. The default value is '0.0.0.0'. -Te enterpriseOID resolve object names (OIDs)Set andthe parse/format object enterprise OID field of a V1TRAP PDU. -Tg genericID Set the generic ID for SNMPv1 TRAPs values ('repository' is the default(V1TRAP). The repositorydefault directoryis must contain compiled MIB 0 (coldStart). -To trapOID Sets the trapOID (1.3.6.1.6.3.1.1.4.1.0) of an modules files only. -Msmi mibRepositoryPath Set the path to the MIB repository to be used to INFORM or TRAP PDU. The default is resolve object names (OIDs) and parse/format object 1.3.6.1.6.3.1.1.5.1. -Ts specificID Set the values ('repository' is the default)specific ID for V1TRAP PDU. The MIBdefault is 0. -Tu repository directoryupTime must contain SMI MIB files Set the sysUpTime field of an INFORM, TRAP, or (v1/v2). The file names of the MIB files have to V1TRAP PDU. -Y privacyPassphrase Set the privacy pass phrase for encrypted SNMPv3 match their MIB module name or there has to be a messages. -a authProtocol Set the propertiesauthentication fileprotocol named 'module-index.properties'used to whichauthenticate mapsSNMPv3 tomessages. theValid module file by values are MD5 '<modulename>.path=<path>' entries. and SHA, -OrsSHA224, SHA256, maxSizeRespPDUSHA384, and SHA512. The maximum size-b of the response PDUbindAddress in bytes. -OtCSV Set local interface and port to use for outgoing For each SNMP row received exactly one row of comma SNMP messages. By default this is 0.0.0.0/0 (host separated values will printed to the console where chosen port on all local IPv4 addresses). -bc engineBootCount Set the engine firstboot columncount containsto the specified rowvalue index. -Otd greater Activatesor denseequal tableto operationzero. modeDefault whichis improveszero. -c community Set the community for SNMPv1/v2c messages. -createAndWait table retrieval performance on regular (dense) Use the createAndWait(5) RowStatus to create new tables. This option must not be used with sparserows instead of createAndGo(4) which might not be tables. -OttCSV supported on certain devices. -d debugLevel Same as -OtCSV except that eachSet row'sthe firstglobal columndebug level for Log4J logging will report the current timeoutput. (millisValid aftervalues are OFF, ERROR, WARN, INFO, 1.1.1970) when the request has beenand sentDEBUG. -Tadhp usmDHParameters agentAddress The octet string (provided Setas thecolon agentseparated address field of a V1TRAP PDU. The hexadecimal string) containing the BER encoded default value is '0.0.0.0'. -Te enterpriseOID Set the enterprise OID field of a V1TRAP PDU. -Tg ASN.1 sequence genericIDof prime (p) and base (g) as defined Set the generic ID for SNMPv1 TRAPs (V1TRAP). The by RFC2786 usmDHParamters OBJECT-TYPE. The default default is 0 (coldStart). -To trapOID Sets thevalue trapOID (1.3.6.1.6.3.1.1.4.1.0) of an is (without line breaks): INFORM or TRAP PDU. The default is 10:69:02:61:00:ff:ff:ff:ff:ff:ff:ff:ff:c9:0f: da:a2:21:68:c2:34:c4:c6:62:8b:80:dc:1c:d1:29: 1.3.6.1.6.3.1.1.5.1. -Ts specificID Set the specific ID for V1TRAP PDU. The default is 02:4e:08:8a:67:cc:74:02:0b:be:a6:3b:13:9b:22: 51:4a:08:79:8e:34:04:dd:ef:95:19:b3:cd:3a:43: 0. -Tu upTime Set the sysUpTime field of an INFORM, TRAP, or 1b:30:2b:0a:6d:f2:5f:14:37:4f:e1:35:6d:6d:51: c2:45:e4:85:b5:76:62:5e:7e:c6:f4:4c:42:e9:a6: V1TRAP PDU. -Y privacyPassphrase Set the privacy pass phrase for encrypted SNMPv3 3a:36:20:ff:ff:ff:ff:ff:ff:ff:ff:02:01:02:02: messages. -a authProtocol01:10 -dhx SetdiffieHellmanPropertyPrefix theThe authenticationproperty protocolprefix used towith the authenticateprivateKeysFile SNMPv3for messages.the Valid values are MD5usmDHKickstartInit and andusmDHKickstartRun SHA, SHA224, SHA256, SHA384, and SHA512.commands. By default -bc engineBootCount Set the engine boot count to the specified value 'org.snmp4j.' is used. -dtls-version dtlsVersion Specifies the DTLS version to use. Possible greater or equal to zero. Default is zero. -c community Setvalues theare communityDTLSv1.0 for SNMPv1/v2c messagesand DTLSv1.2 (default). -createAndWaite engineID Use the createAndWait(5) RowStatus toSet createthe newauthoritative engine ID of the command rows instead of createAndGo(4) which mightresponder notused befor SNMPv3 request messages. If not supported on certain devices. supplied, the -dengine ID will debugLevel be discovered. -f Set the global debug level for Log4J logging 1|2|3|4 Set the OID output format, where 1 = numeric, 2 = output. Valid values are OFF, ERROR, WARN, INFO, last name and numeric index, 3 = last name and and DEBUG. -e engineID formatted Setindex thewithout authoritativequoting, engineand ID4 of= thelast commandname responder used for SNMPv3 request messages. If notand formatted index including hex-formatting of supplied, the engine ID will be discoverednon-printable strings. The default is 4. -fh 1|2|3|4windowSize Set the OIDwindow outputheight format,in whererows. 1If =the numeric,value 2is = lastgreater name and numeric indexthan zero, 3every =windowSize lastrows namethe anduser formatted index without quoting, and 4 = last name is prompted to continue output. Default is zero. -ilo Do not check for andlexicographic formattedordering indexerrors including hex-formatting of while walking a non-printable strings. The default is 4.subtree. Using this option may -h windowSize Set the window height in rows. If the value is cause endless looping if an agent does not greater than zero, every windowSize rows the user implement lexicographic ordering correctly! -l localEngineID Set the local engine ID of the command isgenerator prompted to continue output. Default is zero. -ilo and the Donotification notreceiver checkused for lexicographicSNMPv3 ordering errors request messages. whileThis walkingoption acan subtree.be Usingused thisto option mayavoid causeengine endlessID loopingclashes ifthrough anduplicate agentIDs doesleading notto implement lexicographic ordering correctly!usmStatsNotInTimeWindows reports. -lm localEngineIDmibModuleName SetLoad the localspecified engineMIB IDmodule offrom the command generatorMIB andrepository thespecified notificationby receiverthe used-M foroption. SNMPv3The request messages. This option mibModuleName can be used to avoid a regular expression, e.g. use engine ID clashes through duplicate IDs leading to 'SNMPv2-.*' to load all MIB modules in the repository that start usmStatsNotInTimeWindows reportswith 'SNMPv2-'. -n -m contextName mibModuleName LoadSet the specifiedtarget MIBcontext modulename fromfor theSNMPv3 MIBmessages. repositoryDefault specified byis the -Mempty optionstring. The -p Dump sent mibModuleNameand canreceived bepackets aas regular expression, e.g. usehex string. -r retries Set the number of retries used for 'SNMPv2-.*' to load all MIB modules in the requests. A zero value will send repositoryout thata startrequest with 'SNMPv2-'.exactly once. Default -n contextName Set the target context name for SNMPv3 messages. is 1. -rsl low|basic|secure Set the security level strategy for auto-responses Default is the empty string. -p to REPORT PDUs The default is 'low' for better Dump sent and received packets as hex string. -r retries Set the numbererror ofhandling. retriesUse used'secure' for requestsmax. Asecurity zero value will(i.e. never send outnoAuthNoPriv). aThe requestbasic exactlylevel once.is Default conforming isto 1. RFC 3412 and 3414 -rslallowing low|basic|secure Set the security level strategy for auto-responses 'noAuthNoPriv' for engine ID discovery and wrong to REPORT PDUs The default is 'low' for better username reports. -s error handling. Use 'secure' for max. security Suppress any output on stderr (silent mode). -t timeout (i.e. never send noAuthNoPriv). The basicSet levelthe istimeout in milliseconds between retries. conforming to RFC 3412 andDefault 3414is allowing1000 milliseconds. -tls-cert-fingerprint certFingerprint The fingerprint of the trusted 'noAuthNoPriv' for engine ID discovery and wrong certificate presented by the remote SNMP engine as username reports. -s hex string. If the fingerprint does not match, Suppress any output on stderr (silent mode). -t timeout connection will not Setbe theestablished. timeoutUse inthis millisecondsoption between retries. with the "tls:" Default is 1000 millisecondsor "dtls:" transport domain. -tls-local-id certAlias The local certificate alias identity which selects a certificate chain from the local key store. Only the selected certificate chain will be presented to the remote SNMP engine. Use this option with the "tls:" or "dtls:" transport domain. -tls-peer-id subjectDN The subject DN (e.g., "EMAILADDRESS=email@host.com, C=US, CN=My Name") of the trusted certificate presented by the remote SNMP engine ID. Use this option with the "tls:" or "dtls:" transport domain. -tls-trust-ca issuerDN The issuer DN (e.g., "Company Name CA") of a trusted certification authority (CA) presented by the remote SNMP engine ID for TLS and DTLS. -tls-version tlsVersion The TLS version to use with the 'tls:' transport protocol. Currently only 'TLSv1', 'TLSv1.1', and 'TLSv1.2' are supported with Java 7 or later. 'TLSv1' is the default which is supported with Java 6 too. -u securityName Set the security name for authenticated v3 messages. -v 1|2c|3 Set the SNMP protocol version to be used. Default is 3. -w consoleWidth Specifies the width of the console output, default is 80 characters. -y privacyProtocol Set the privacy protocol to be used to encrypt SNMPv3 messages. Valid values are DES, AES (AES128), AES192, AES256, AES192p, AES256p, and 3DES(DESEDE). The AES protocols that end with 'p' (for proprietary) are using a non-standardized key extension algorithm from 3DES. Up |