系统的日志经常报这些日志出来
Sep 21 04:10:02 DB2 last message repeated 16 times
Sep 21 04:15:03 DB2 last message repeated 16 times
Sep 21 04:15:03 DB2 last message repeated 15 times
Sep 21 04:20:03 DB2 snmpd[12064]: Connection from UDP: [192.168.1.100]:35441
Sep 21 04:20:03 DB2 snmpd[12064]: Received SNMP packet(s) from UDP: [192.168.1.100]:35441
Sep 21 04:20:03 DB2 snmpd[12064]: Connection from UDP: [192.168.1.100]:35441
Sep 21 04:25:02 DB2 last message repeated 15 times
Sep 21 04:30:03 DB2 last message repeated 16 times
Sep 21 04:35:03 DB2 last message repeated 16 times
Sep 21 04:40:02 DB2 last message repeated 16 times
Sep 21 04:40:02 DB2 last message repeated 15 times
这些信息都是cacti来snmpd来抓取数据时引起的相关记录。不知哪位大侠知道造成这日志的原因是什么呢?
我想把这些日志都过滤掉。如果是centos的修改/etc/init.d/snmpd
把这一行 OPTIONS="-Lsd -Lf /dev/null -p /var/run/snmpd.pid -a"
改成 OPTIONS="-LS 0-4 d -Lf /dev/null -p /var/run/snmpd.pid -a"
保存重启,详细的参数意思,可以用 man snmpd和man snmpcmd来查看
man snmpcmd中对日志等级的定义
0 or ! for LOG_EMERG,
1 or a for LOG_ALERT,
2 or c for LOG_CRIT,
3 or e for LOG_ERR,
4 or w for LOG_WARNING,
5 or n for LOG_NOTICE,
6 or i for LOG_INFO, and
7 or d for LOG_DEBUG.
阅读(1724) | 评论(0) | 转发(0) |