Bug #43970 Some SNMP manager can't detect 'Application Error' SNMP notifications.
Submitted: 31 Mar 2009 1:58 Modified: 7 Aug 2009 10:46
Reporter: Meiji KIMURA Email Updates:
Status: Closed Impact on me:
Category:MySQL Enterprise Monitor: Server Severity:S3 (Non-critical)
Version:2.0.5 OS:Microsoft Windows
Assigned to: Sloan Childers CPU Architecture:Any

[31 Mar 2009 1:58] Meiji KIMURA
I can enable SNMP Notifications, and can send a test notification with "On Save send test trap (optional)".

1) Up/Down Application
2) Advisor Event with a severity of
3) Application Error

All SNMP Managers can detect 1) and 2), but some SNMP Manager cannot detect 3) on Windows.

I tested these SNMP Manager.

a) SNMP Trap Receiver(Japanese)

b) Trap Reciever

c) Net-SNMP

c) can detect 3), but a) and b) cannot detect 3).

I don't know MEM's message is improper or Manager's implementation are improper. The fact is described as above.

How to repeat:
1) Enable SNMP Notifications of 'Application Error' and can send a test notification with "On Save send test trap (optional)".

2) Try to trap these messages.

Suggested fix:
[31 Mar 2009 2:01] Meiji KIMURA
Dump of SNMP message detected  by net-snmp

Attachment: snmp_dump.txt (text/plain), 32.63 KiB.

[2 Apr 2009 2:15] Sloan Childers
fixed in trunk ... local revision 6902

  - continue to use SMIv1 default OctetString max length as the default
  - add an override for users which have SNMP trap receivers that don't
    follow the protocol (many use the DisplayString length of 255 as the max
    OctetString which in reality is unlimited in SMIv1 and 64k in SMIv2.
[8 Apr 2009 18:44] Keith Russell
Patch installed in versions =>
[9 Jun 2009 20:43] Sloan Childers
To test the SNMP octetstring max size override set the following MEM server property and then restart the MEM server.  The value 2048 in the example will be the maximum SNMP octetstring size we would then send in any of our SNMP traps.  Note that this value may need adjusting depending on the behavior of the SNMP manager.

INSERT INTO map_entries VALUES (1,'2048','snmp.octetstring');
[10 Jun 2009 19:57] Sloan Childers
Tested with two out of the three SNMP trap receivers.  I'm setting the state to documenting so the customer will have the required workaround in the docs for the 2.1 release.
[7 Aug 2009 10:46] Tony Bedford
An entry was added to the 2.1.0 changelog (includes work around):

Some SNMP managers could not detect “Application Error” SNMP notifications.

This happened because some SNMP managers do not follow the protocol correctly. Some use the DisplayString length of 255 as the maximum OctetString, but this is in fact unlimited in SMIv1 and 64k in SMIv2.

To work around this issue it is possible to override the correct behavior to allow non-comformant SNMP Managers to detect all messages. This is achieved by overriding the OctetString maximum size by setting a server property. This is done by entering SQL such as the following:

INSERT INTO map_entries VALUES (1,'2048','snmp.octetstring');

In this example the value 2048 will be the maximum SNMP OctetString size that would sent in any SNMP traps. After setting this property the server will need to be restarted. Note that the value used may need adjusting depending on the behavior of the SNMP manager.