Bug #24051
Add SNMP log level and default to LOG_ERR
Status:
Resolved
Priority:
No priority
Assignee:
William Grzybowski
Category:
Middleware
Target version:
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
tn z
ChangeLog Required:
No
Description
Snmpd notices warning blowing up logs; the default should be less chatty; as seen internally elsewhere;
#dmesg -a | tail :root:~/ash:8:00:46:527ixbackup-b May 18 08:00:04 snmpd[2971]: error on subcontainer 'swrun container' insert (-1) May 18 08:00:04 snmpd[2971]: error on subcontainer 'swrun container' insert (-1) May 18 08:00:04 snmpd[2971]: error on subcontainer 'swrun container' insert (-1) from /etc/rc.conf.local: snmpd_flags=\"-Ls5d\ <<<-- too chatty
from snmpcmd(5)
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.
Setting it to alert by default and allowing configuration to jack it up again would be best; alternately - an auxprop or flags control field would.
Related issues
Associated revisions
feat(snmp): add log level and change default to LOG_ERR
Ticket: #24051
feat(snmp): add log level and change default to LOG_ERR
Ticket: #24051
feat(snmp): add log level and change default to LOG_ERR
Ticket: #24051
Add new Log Level field to SNMP.
Ticket: #24051
feat(snmp): add log level and change default to LOG_ERR
Ticket: #24051
History
#1
Updated by William Grzybowski over 3 years ago
- Status changed from Unscreened to Screened
#2
Updated by Ash Gokhale over 3 years ago
It might also that the async loop is throwing some exception here:
github_src/freenas/gui/tools/freenas-snmpd.py: unmodified, readonly: line 195 of 35 class Loop_Sockserver(threading.Thread): def __init__(self): super(Loop_Sockserver, self).__init__() self.daemon = True self.obj = SockSelect() def run(self): try: asyncore.loop() except Exception as e: syslog(LOG_ALERT, str(e)) <---- another possible leak to syslog finally:
This blows up the logs with this sort of output:
Jun 1 13:43:52 TNC2 snmpd[3217]: params 1017/1024 -n #pragma D option quiet inline int OPT_time = 0; inline int OPT_txg = 0; inline int OPT_pool = 0; inline int OPT_mega = 0; inline int INTERVAL = 1; inline int LINES = -1; inline int COUNTER = 1; inline int FILTER = 0; inline string POOL = ""; dtrace:::BEGIN { /* starting values */ MEGA = 1000000; counts = COUNTER; secs = INTERVAL; interval = INTERVAL; interval == 0 ? interval++ : 1; line = 0; last_event[""] = 0; nused=0; nused_max_per_sec=0; nused_per_sec=0; size=0; size_max_per_sec=0; size_per_sec=0; syncops=0; size_4k=0; size_4k_32k=0; size_32k=0; OPT_txg ? printf("waiting for txg commit...\n") : 1; } /* * collect info when zil_lwb_write_start fires */ fbt::zil_lwb_write_start:entry /OPT_pool == 0 || POOL == args[0]->zl_dmu_pool->dp_spa->spa_name/ { nused += args[1]->lwb_nused; nused_per_sec += args[1]->lwb_nused; size += args[1]->lwb_sz; size_per_sec += args[1]->lwb_sz; syncops+ .... ....
#3
Updated by Ash Gokhale over 3 years ago
- Tracker changed from Feature to Bug
- Priority changed from Nice to have to Expected
- Seen in set to 9.10.2-U3
- Hardware Configuration updated (diff)
- Migration Needed set to No
This feature is getting bugified because it elides logs required for field support - XYZ-920-81636.
#4
Updated by Ash Gokhale over 3 years ago
- Subject changed from add snmpd log level control to add snmpd log level control - lower log volume
- Category changed from 2 to 55
#5
Updated by William Grzybowski over 3 years ago
- Status changed from Screened to Ready For Release
#6
Updated by William Grzybowski over 3 years ago
- Is duplicate of Bug #24249: iXsystems support request (John Sanderson) added
#7
Updated by William Grzybowski over 3 years ago
- Is duplicate of Bug #25298: SNMP dtrace log added
#8
Updated by Dru Lavigne over 3 years ago
- Subject changed from add snmpd log level control - lower log volume to Add SNMP log and default to LOG_ERR
#9
Updated by Dru Lavigne over 3 years ago
- Subject changed from Add SNMP log and default to LOG_ERR to Add SNMP log level and default to LOG_ERR
#10
Updated by Dru Lavigne over 3 years ago
- Target version changed from 11.1 to 11.1-BETA1
#11
Updated by Dru Lavigne about 3 years ago
- Status changed from Ready For Release to Resolved
#12
Updated by Nick Wolff about 3 years ago
- QA Status Test Passes FreeNAS added
- QA Status deleted (
Not Tested)
#13
Updated by Joe Maloney about 3 years ago
- Needs QA changed from Yes to No