blank.gif (43 bytes)

Church Of The
Swimming Elephant

dns | icmp | ietf | ined | inet | job | map | mib | netdb | ntp | snmp | sunrpc | syslog | term | udp

snmp get vbl [script]

The snmp# get session command retrieves the list of instances as specified in the varbind list vbl by using an SNMP get-request. 

If the get session command contains a callback script, then the command sends the get-request and returns immediately. 

The result is the request id for the asynchronous request. The get session command is processed synchronously if the callback script is absent. In this case, the received varbind list is returned. 

The command fails with a Tcl error if the agent does not respond or if a protocol error happens.

Below is an example for a synchronous get request to retrieve some variables of the system group. The Tcl catch command is used to handle any errors:

set vbl {SNMPv2-MIB!sysDescr.0\
set err [catch {$s get $vbl} vbl]
if {$err == 0} {
    puts $vbl

The code below implements the same get request with an asynchronous get request:

set vbl {SNMPv2-MIB!sysDescr.0\
$s get $vbl {
    if {”%E” == “noError”} { 
        puts “%V” 



Protect yourself from cyberstalkers, identity thieves, and those who would snoop on you.
Stop spam from invading your inbox without losing the mail you want. We give you more control over your e-mail than any other service.
Block popups, ads, and malicious scripts while you surf the net through our anonymous proxies.
Participate in Usenet, host your web files, easily send anonymous messages, and more, much more.
All private, all encrypted, all secure, all in an easy to use service, and all for only $5.95 a month!

Service Details

Have you gone to church today?
All pages ©1999, 2000, 2001, 2002, 2003 Church of the Swimming Elephant unless otherwise stated
Church of the Swimming Elephant©1999, 2000, 2001, 2002, 2003 is a wholly owned subsidiary of Packetderm, LLC.

Packetderm, LLC
210 Park Ave #308
Worcester, MA 01609