월간 인기 게시물

게시물 1,372건
   
snmpd[2197]: error on subcontainer 'ia_addr' insert (-1)
글쓴이 : 최고관리자 날짜 : 2018-08-17 (금) 09:53 조회 : 15637
글주소 :
                                


증상 : 
Ubuntu 16.04 환경에서 snmp 설정하고 나서 30초 단위로 첨부된 이미지와 같은 에러발생 


원인 :
결론부터 말하자면 snmp 버그로 보인다. (https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=559109)
Ubuntu & Debian 계열에서는 SNMP를 설치하고 나면 다음과 같은 옵션을 가지게 된다.
이중 로깅 옵션(-L flag)을 보게 되면 여기서는 -Lsd 즉 로그 디버그 수준에 메세지도 syslog 에 남기라고 되어있다.
LOG_DEBUG 를 제외시키기 위헤서는 7(d) 레벨에서 6(i) 레벨로 바꾸어서 운영하면 된다.


$ cat /etc/default/snmpd 
.........................................
# snmpd options (use syslog, close stdin/out/err).
SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -g snmp -I -smux,mteTrigger,mteTriggerConf -p /run/snmpd.pid'


조치(해결) :
보통은 LOG_INFO(6) 나 LOG_ERROR(3) 을 권장한다.
$ sudo sed -i "s|-Lsd|-LS6d|" /etc/default/snmpd

$ cat /etc/default/snmpd 
.........................................
# snmpd options (use syslog, close stdin/out/err).
SNMPDOPTS='-LS6d -Lf /dev/null -u snmp -g snmp -I -smux,mteTrigger,mteTriggerConf -p /run/snmpd.pid'

$ sudo /etc/snmpd/snmpd restart 



LOGGING OPTIONS

The mechanism and destination to use for logging of warning and error messages can be controlled by passing various parameters to the -L flag.
-Le
Log messages to the standard error stream.
-Lf FILE
Log messages to the specified file.
-Lo
Log messages to the standard output stream.
-Ls FACILITY
Log messages via syslog, using the specified facility ('d' for LOG_DAEMON, 'u' for LOG_USER, or '0'-'7' for LOG_LOCAL0 through LOG_LOCAL7).

There are also "upper case" versions of each of these options, which allow the corresponding logging mechanism to be restricted to certain priorities of message. Using standard error logging as an example:

-LE pri
will log messages of priority 'pri' and above to standard error.
-LE p1-p2
will log messages with priority between 'p1' and 'p2' (inclusive) to standard error.

For -LF and -LS the priority specification comes before the file or facility token. The priorities recognised are:

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.

Normal output is (or will be!) logged at a priority level of LOG_NOTICE


이름 패스워드
비밀글 (체크하면 글쓴이만 내용을 확인할 수 있습니다.)
왼쪽의 글자를 입력하세요.
   

 



 
사이트명 : 모지리네 | 대표 : 이경현 | 개인커뮤니티 : 랭키닷컴 운영체제(OS) | 경기도 성남시 분당구 | 전자우편 : mojily골뱅이chonnom.com Copyright ⓒ www.chonnom.com www.kyunghyun.net www.mojily.net. All rights reserved.