context.pty manual page
Table of Contents

NAME

context.pty - context info configuration for SNMPv2 entities

SYNOPSIS

contextId contextIndex contextViewIndex LocalEntity LocalTime PDst PSrc PContext StorageType Local

DESCRIPTION

The configuration file context.pty is one of several configuration files required by the SNMPv2 entities. The default location of context.pty is /etc/opt/snm/agent or /etc/opt/snm/manager for Solaris 2.x and /etc/snm/agent or /etc/snm/manager for Solaris 1.x, but can be specified by the environment variable SR_MGR_CONF_DIR or SR_AGT_CONF_DIR.

The context.pty file is used by SNMPv2 agents and managers to define either a party's MIB view or a proxy relationship. For more information, please refer to RFC1447.

Each entry in the file consists of 2 lines: contextId contextIndex contextViewIndex LocalEntity LocalTime PDst PSrc PContext StorageType Local where

contextId
is the context identifier which uniquely identifies this context.
This field is an OID.

contextIndex
is the unique index for this SNMPv2 context. This index is used by the ACL table (see acl.pty(5) ) when determining access control. There are 0 or more entries in the ACL table ( aclResources ) that point to this value in the context table.
This field is an integer in the range of 1 to 65535, inclusive.

contextViewIndex
determines whether this context is local or remote. A value greater than zero indicates that this is a local context and is, therefore, an index into the view table. There must exist at least one entry in the view table configuration file, view.pty, with a viewIndex matching this contextViewIndex. The entry in the view table will determine the MIB view available in this context.
See view.pty(5) and RFC1447 for more information on the view.pty configuration file.
A value of zero indicates a proxy relationship, and further information will be provided by PDst, PSrc, and PContext.
This field is an integer in the range of 0 to 65535, inclusive.

LocalEntity
if the corresponding value for contextViewIndex is greater than zero, this field identifies the local entity whose management information is in the context's MIB view:
The empty string, represented by .I - , indicates that the MIB view contains the entity's own local management information.
If not -, the string indicates that the MIB view contains management information of some other local entity, such as Hub1.
When the corresponding value for contextViewIndex is zero, indicating proxy, this field is ignored, but must contain a value; the place-holder string, - , is a perennial favorite.
This field is an octet string.

LocalTime
if the contextViewIndex indicates this is a local context, (i. e., contextViewIndex > 0), identifies the temporal context of the management information in the MIB view.
Possible values for this field are: currentTime - refers to management information at the present time.
restartTime - refers to management information upon the next re-initialization of the managed device. cacheTime.N where N is the number of seconds, refers to management information that is in cache and is guaranteed to be at most N seconds old. This field is an OID.

PDst if this is a proxy relationship (i. e., contextViewIn_dex = 0), this field identifies a SNMPv2 party which is the proxy destination of a proxy relationship. If the value of contextViewIndex is greater than zero, this field must have a value of "0.0". This field is an OID and is the contextProxyDstParty field referred to in RFC1447.

PSrc is the contextProxySrcParty field. If the

corresponding value for contextViewIndex is equal to zero, this field identifies a SNMPv2 party which is the proxy source of a proxy relationship. The interpretation of this value depends on the value of the transport domain (see agt.pty(5) and RFC1447) associated with the SNMPv2 party used as the proxy destination in this proxy relationship.
If the value of contextViewIndex is greater than zero, this field must have a value of "0.0". This field is an OID.

PContext
is the contextProxyContext field. If the corresponding value for contextViewIndex is equal to zero, then the value for this field identifies the context of a proxy relationship. Interpretation of an instance of this object depends on the value of the transport domain (see TDomain in agt.pty(5) ) associated with the SNMPv2 party used as the proxy destination in this proxy relationship. If the value of contextViewIndex is greater than zero, this field must have a value of "0.0". This field is an OID.

StorageType
indicates the storage type for this row in the party table. Possible values are:
other
volatile
nonVolatile
permanent
According to RFC1447,
· volatile is lost upon reboot, e. g., in RAM, · nonVolatile is backed up by stable storage, e. g., in NVRAM,
· permanent cannot be changed or deleted, e. g., in ROM,
and "other" is provided in the unlikely event that someone will find a need for a storage type not covered by the other three.
This field is a case-sensitive string corresponding to one of the above values.

Local
indicates to an agent whether this context is local to this SNMPv2 agent. Local indicates "residing at the address with the entity."

This field has two possible values: true - it is local
or
false - it is not local
Local is used in conjunction with contextViewIndex and causes different responses depending on its value. The only time Local is allowed to be false, is when contextViewIndex is 0, indicating this is a proxy context, and the incoming PDU is a proxy get-response. Otherwise, a Local of false will cause the counter snmpStatsUnknownContexts to be incremented, and the packet will be dropped silently.
The field is a case-sensitive string corresponding to one of the above values.

EXAMPLE

The context entry:

initialContextId.192.147.142.16.1 1 1 currentTime 0.0 0.0 0.0 nonVolatile true
defines this context as follows:

initialContextId.192.147.142.16.1 is the contextId and the contextIndex is one.

The contextViewIndex has a value of one, indicating this is not a proxy and that the MIB view for this context is all subtrees in the view table that have a viewIndex of one.

The LocalEntity field is the empty string indicating that the information is for the local entity.

The LocalTime field has a value of currentTime, and the PDst, PSrc, and PContext fields have a value of "0.0" since this is not a proxy but a local context.

Store this context in nonVolatile storage, such as NVRAM.

Local field is true, indicating this is a local context executing at the local address.

FILES

Additional SNMPv2 Configuration Files
When the agent is compiled with either SNMPv2 or both SNMPv1 and SNMPv2 defined, the configuration files acl.pty, agt.pty, context.pty, snmpv2d.conf and view.pty are required for the agent side, and acl.pty, context.pty, mgr.cnf, mgr.pty, and view.pty are required for the manager side. acl.pty
Access control privileges for the SNMPv2 parties.

agt.pty
Initial party table information for the agent.

context.pty
Context information for the SNMPv2 parties.

mgr.cnf
Configuration information for the managers.

mgr.pty
Initial party table information for the managers.

snmpv2d.conf
Configuration information for the SNMPv1 entities.

view.pty
MIB view information for the SNMPv2 parties.

For Solaris 2.x, the files are located under:

/etc/opt/snm/{agent,manager}/acl.pty
/etc/opt/snm/agent/agent.pty
/etc/opt/snm/{agent,manager}/context.pty
/etc/opt/snm/manager/manager.cnf
/etc/opt/snm/manager/manager.pty
/etc/opt/snm/agent/snmpv2d.conf
/etc/opt/snm/{agent,manager}/view.pty

For Solaris 1.x, the files are located under:

/etc/snm/{agent,manager}/acl.pty
/etc/snm/agent/agent.pty
/etc/snm/{agent,manager}/context.pty
/etc/snm/manager/manager.cnf
/etc/snm/manager/manager.pty
/etc/snm/agent/snmpv2d.conf
/etc/snm/{agent,manager}/view.pty

SEE ALSO

v2install(1), acl.pty(5), agt.pty(5), context.pty(5), mgr.cnf(5), mgr.pty(5), snmpv2d.conf(5), view.pty(5), SNMP RFCs (RFC1155 RFC1157 RFC1212 RFC1213 RFC1215, RFCs 14411452)


Table of Contents