notification_log.h
上传用户:wxp200602
上传日期:2007-10-30
资源大小:4028k
文件大小:2k
源码类别:

SNMP编程

开发平台:

Unix_Linux

  1. #ifndef NOTIFICATION_LOG_H
  2. #define NOTIFICATION_LOG_H
  3. #include <net-snmp/agent/agent_handler.h>
  4. /*
  5.  * function declarations 
  6.  */
  7. void            init_notification_log(void);
  8. Netsnmp_Node_Handler nlmLogTable_handler;
  9. Netsnmp_Node_Handler nlmLogVariableTable_handler;
  10. Netsnmp_Trap_Handler notification_handler;
  11. void
  12.                 log_notification(struct hostent *host, netsnmp_pdu *pdu,
  13.                                  netsnmp_transport *transport);
  14. #define NETSNMP_DS_APP_DONT_LOG    9    /* must match notification_log. */
  15. /*
  16.  * column number definitions for table nlmLogTable 
  17.  */
  18. #define COLUMN_NLMLOGINDEX 1
  19. #define COLUMN_NLMLOGTIME 2
  20. #define COLUMN_NLMLOGDATEANDTIME 3
  21. #define COLUMN_NLMLOGENGINEID 4
  22. #define COLUMN_NLMLOGENGINETADDRESS 5
  23. #define COLUMN_NLMLOGENGINETDOMAIN 6
  24. #define COLUMN_NLMLOGCONTEXTENGINEID 7
  25. #define COLUMN_NLMLOGCONTEXTNAME 8
  26. #define COLUMN_NLMLOGNOTIFICATIONID 9
  27. /*
  28.  * column number definitions for table nlmLogVariableTable 
  29.  */
  30. #define COLUMN_NLMLOGVARIABLEINDEX 1
  31. #define COLUMN_NLMLOGVARIABLEID 2
  32. #define COLUMN_NLMLOGVARIABLEVALUETYPE 3
  33. #define COLUMN_NLMLOGVARIABLECOUNTER32VAL 4
  34. #define COLUMN_NLMLOGVARIABLEUNSIGNED32VAL 5
  35. #define COLUMN_NLMLOGVARIABLETIMETICKSVAL 6
  36. #define COLUMN_NLMLOGVARIABLEINTEGER32VAL 7
  37. #define COLUMN_NLMLOGVARIABLEOCTETSTRINGVAL 8
  38. #define COLUMN_NLMLOGVARIABLEIPADDRESSVAL 9
  39. #define COLUMN_NLMLOGVARIABLEOIDVAL 10
  40. #define COLUMN_NLMLOGVARIABLECOUNTER64VAL 11
  41. #define COLUMN_NLMLOGVARIABLEOPAQUEVAL 12
  42. #endif                          /* NOTIFICATION_LOG_H */