.TH snmp_target_mib 3erl "snmp 5.7.3" "Ericsson AB" "Erlang Module Definition" .SH NAME snmp_target_mib \- Instrumentation Functions for SNMP-TARGET-MIB .SH DESCRIPTION .LP The module \fIsnmp_target_mib\fR\& implements the instrumentation functions for the SNMP-TARGET-MIB, and functions for configuring the database\&. .LP The configuration files are described in the SNMP User\&'s Manual\&. .LP Legacy API functions \fIadd_addr/10\fR\& that does not specify transport domain, and \fIadd_addr/11\fR\& that has got separate \fIIpAddr\fR\& and \fIPortNumber\fR\& arguments still work as before for backwards compatibility reasons\&. .SH "DATA TYPES" .LP See the data types in \fIsnmpa_conf\fR\&\&. .SH EXPORTS .LP .B configure(ConfDir) -> void() .br .RS .LP Types: .RS 3 ConfDir = string() .br .RE .RE .RS .LP This function is called from the supervisor at system start-up\&. .LP Inserts all data in the configuration files into the database and destroys all old rows with StorageType \fIvolatile\fR\&\&. The rows created from the configuration file will have StorageType \fInonVolatile\fR\&\&. .LP All \fIsnmp\fR\& counters are set to zero\&. .LP If an error is found in the configuration file, it is reported using the function \fIconfig_err/2\fR\& of the error report module, and the function fails with the reason \fIconfiguration_error\fR\&\&. .LP \fIConfDir\fR\& is a string which points to the directory where the configuration files are found\&. .LP The configuration files read are: \fItarget_addr\&.conf\fR\& and \fItarget_params\&.conf\fR\&\&. .RE .LP .B reconfigure(ConfDir) -> void() .br .RS .LP Types: .RS 3 ConfDir = string() .br .RE .RE .RS .LP Inserts all data in the configuration files into the database and destroys all old data, including the rows with StorageType \fInonVolatile\fR\&\&. The rows created from the configuration file will have StorageType \fInonVolatile\fR\&\&. .LP Thus, the data in the SNMP-TARGET-MIB, after this function has been called, is the data from the configuration files\&. .LP All \fIsnmp\fR\& counters are set to zero\&. .LP If an error is found in the configuration file, it is reported using the function \fIconfig_err/2\fR\& of the , and the function fails with the reason \fIconfiguration_error\fR\&\&. .LP \fIConfDir\fR\& is a string which points to the directory where the configuration files are found\&. .LP The configuration files read are: \fItarget_addr\&.conf\fR\& and \fItarget_params\&.conf\fR\&\&. .RE .LP .B set_target_engine_id(TargetAddrName, EngineId) -> boolean() .br .RS .LP Types: .RS 3 TargetAddrName = string() .br EngineId = string() .br .RE .RE .RS .LP Changes the engine id for a target in the \fIsnmpTargetAddrTable\fR\&\&. If notifications are sent as Inform requests to a target, its engine id must be set\&. .RE .LP .B add_addr(Name, Domain, Addr, Timeout, Retry, TagList, Params, EngineId, TMask, MMS) -> Ret .br .RS .LP Types: .RS 3 Name = string() .br Domain = transportDomain() .br Addr = transportAddress() % Default port is 162 .br Timeout = integer() .br Retry = integer() .br TagList = string() .br ParamsName = string() .br EngineId = string() .br TMask = transportAddressMask() % Depends on Domain .br MMS = integer() .br Ret = {ok, Key} | {error, Reason} .br Key = term() .br Reason = term() .br .RE .RE .RS .LP Adds a target address definition to the agent config\&. Equivalent to one line in the \fItarget_addr\&.conf\fR\& file\&. .RE .LP .B delete_addr(Key) -> Ret .br .RS .LP Types: .RS 3 Key = term() .br Ret = ok | {error, Reason} .br Reason = term() .br .RE .RE .RS .LP Delete a target address definition from the agent config\&. .RE .LP .B add_params(Name, MPModel, SecModel, SecName, SecLevel) -> Ret .br .RS .LP Types: .RS 3 Name = string() .br MPModel = v1 | v2c | v3 .br SecModel = v1 | v2c | usm .br SecName = string() .br SecLevel = noAuthNoPriv | authNoPriv | authPriv .br Ret = {ok, Key} | {error, Reason} .br Key = term() .br Reason = term() .br .RE .RE .RS .LP Adds a target parameter definition to the agent config\&. Equivalent to one line in the \fItarget_params\&.conf\fR\& file\&. .RE .LP .B delete_params(Key) -> Ret .br .RS .LP Types: .RS 3 Key = term() .br Ret = ok | {error, Reason} .br Reason = term() .br .RE .RE .RS .LP Delete a target parameter definition from the agent config\&. .RE