Description:
In our environment we monitor several mysqlds on a single host with a single agent using the standard method or files located within the etc/instances/ directory.
This environment changes a lot and as such we need to add, remove, or move mysqld instances between the different hosts. Adding a new configuration works fine.
If we remove a mysqld instance then it is shown as "crossed out" in the dashboard (not reachable).
If we remove the agent configuration for that instance, that is rm -rf etc/instances/<instance_name> then there is no change in what is shown on the dashboard.
How to repeat:
N/A
Suggested fix:
My expectation would be that the agent should report the instances it is configured to manage, and the dashboard should "see" that an instance previously managed by the agent is no longer managed by it. As such it should be shown in "red" (dead instance) and be elegible for deletion.
Currently the only way to do this is to shutdown the agent and then delete the instance information and finally start up the agent again. This is inconvenient.
Also if the mysqlds monitored by the agent change (addition or removal) it would be nice to get some sort of notification of this "event":
1. found new mysql instance ZZZZZZZZ on host XXXXXX, or
2. existing mysql instance ZZZZZZZZ removed from host XXXXXX
This would make maintenance and cleanups much easier as it's now rather a tedious process to maintain.