资源简介
snmp监控源码,文档在:
http://download.csdn.net/detail/kl222/4366325
代码片段和文件信息
/*
* Note: this file originally auto-generated by mib2c using
* $
*/
#include
#include
#include
#include “alarmNotification.h“
#include “database.h“
#include “reachdefine.h“
#include “reachAlarmNotifiactionTable_access.h“
#include
#define MAX_SQL_BUFFER 1024
reachAlarmNotifiactionTable* g_AlarmNotification = NULL;
struct _ALARM_GLOBAL_PARAS gAlarmNotificationTrapParas;
int
send_alarmNotification_trap(reachAlarmNotifiactionTable* pNotificationTable)
{
netsnmp_variable_list *var_list = NULL;
size_t nLen = 0;
/*
* In the notification we have to assign our notification OID to
* the snmpTrapOID.0 object. Here is it‘s definition.
*/
oid objid_snmptrap[] = { 1 3 6 1 6 3 1 1 4 1 0 };
size_t objid_snmptrap_len = OID_LENGTH(objid_snmptrap);
extern oid snmptrap_oid;
const oid alarmNotification_oid[] = { 136141197613 };
const oid reachAlarmNotifiactionNo_oid[] = { 13614119761211 0/* insert index here */ };
const oid reachAlarmNotifiactionId_oid[] = { 13614119761212 0/* insert index here */ };
const oid reachAlarmNotifiactionName_oid[] = { 13614119761213 0/* insert index here */ };
const oid reachAlarmNotifiactionType_oid[] = { 13614119761214 0/* insert index here */ };
const oid reachAlarmNotifiactionCategorie_oid[] = { 13614119761215 0/* insert index here */ };
const oid reachAlarmNotifiactionInfo_oid[] = { 13614119761216 0/* insert index here */ };
const oid reachAlarmNotifiactionExtInfo_oid[] = { 13614119761217 0/* insert index here */ };
const oid reachAlarmNotifiactionLevel_oid[] = { 13614119761218 0/* insert index here */ };
const oid reachAlarmNotifiactionIp_oid[] = { 13614119761219 0/* insert index here */ };
const oid reachAlarmNotifiactionTime_oid[] = { 136141197612110 0/* insert index here */ };
DEBUGMSGTL((“reachAlarmSubscribeTrap:“ “send_alarmNotification_trap start...\n“));
/*
* Set the snmpTrapOid.0 value
*/
snmp_varlist_add_variable(&var_list
objid_snmptrap objid_snmptrap_len
ASN_object_ID
alarmNotification_oid sizeof(alarmNotification_oid));
/* snmp_varlist_add_variable(&var_list
&snmptrap_oid OID_LENGTH(snmptrap_oid)
ASN_object_ID
alarmNotification_oid sizeof(alarmNotification_oid));*/
/*
* Add any objects from the trap definition
*/
snmp_varlist_add_variable(&var_list
reachAlarmNotifiactionNo_oid OID_LENGTH(reachAlarmNotifiactionNo_oid)
ASN_INTEGER
/* Set an appropriate value for reachAlarmNotifiactionNo */
&pNotificationTable->reachAlarmNotifiactionNo sizeof(pNotificationTable->reachAlarmNotifiactionNo));
snmp_varlist_add_variable(&var_list
相关资源
- 基于SNMP++提取进程内存使用,CPU占用
- 《NET-SNMP_张春强著高清版pdf》
- Snmputil工具 绿色免费版(包含Snmputi
- 基于SNMP网络管理系统的设计与实现
- 网络管理综合性实验报告snmp的mibwal
- 网络抓包snmp数据包
- 100M光纤收发器原理图OrCad文件格式
- snmp++v3.2.25.tar.gz及libdes-l-4.01a.tar.gz
- snmp++ 编译snmp_pp.lib工程
- net-snmp-5.7.2-37.el7.x86_64.rpm
- snmpwalk.exewindows 平台
- 基于snmp的网络流量监控系统的设计与
- 自己编的SNMP网络监控的软件
- SNMPutil & SNMPutilG 两个小工具
- snmputil工具
- snmp的get和set测试工具
- Net-SNMP代理开发程序
- Gx00_83-05-33-SNMP.zip
- SNMP++/Agent++ 开发手册
- snmp++和agent++开发指南
- SNMP网络拓扑发现.doc
- snmp_Get_Set_Trap工具
- 利用SNMP#NET做trap接收器
- SNMP+MIB完整手册
- nagios-snmp-plugins-1.2.tar.gz
- SNMP实验报告
- 用net-snmp的api实现trap接收,windows+li
- net-snmp开始教程
- mib2中节点的详细中文描述
- snmp4j中文版阅读文档
评论
共有 条评论