Bug #43244 Agent crash if Master_Host value from Show Slave Status is a number
Submitted: 26 Feb 2009 22:58 Modified: 9 Jan 2015 10:37
Reporter: Diego Medina Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Enterprise Monitor: Agent Severity:S3 (Non-critical)
Version:2.0.5.7146 OS:Any
Assigned to: Assigned Account CPU Architecture:Any

[26 Feb 2009 22:58] Diego Medina
Description:
If you mock SHOW SLAVE STATUS and for the field MASTER_HOST, you send a numeric value, the agent will crash with this message 

Shutting down MySQL Enterprise agent service...**
** ERROR:(job_collect_mysql.c:943):agent_item_class_update_from_fieldnames: assertion failed: (master_host->type == AGENT_ITEM_TYPE_STRING)

How to repeat:
1- Setup a proxy in between the agent and the mysqld and use this lua script

https://inside.mysql.com/wiki/ET:HeavyLoadMocked#Where_do_I_get_it.3F

(will be public soon)

2- Start the agent
3- Boom, error message on the terminal

Suggested fix:
Do not crash, just ignore the wrong data?
[26 Feb 2009 22:59] Diego Medina
Use this file for the proxy

Attachment: mockload.lua (application/octet-stream, text), 59.83 KiB.

[6 Mar 2009 19:51] Mark Matthews
The agent should instead log that it got an unexpected type, and just toss out anything related to slave status, since there's no way to ensure that it's looking at valid data from mysql.