Bug #96652 CPU load on MySql Server due to MySqlRouter
Submitted: 26 Aug 2019 10:01 Modified: 30 Aug 2019 6:34
Reporter: david deman Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Router Severity:S5 (Performance)
Version:8.0.14, 8.0.17 OS:CentOS
Assigned to: CPU Architecture:Any

[26 Aug 2019 10:01] david deman
Description:

 Architecture: 

      - 3 nodes Cluster DB
      - 10 Several MySql Router Client

 Without any DB traffic (except traffic due to MySqlRouter), The first node have a 2.5 cpu load average while the two others node just have a cpu load average to 0.5

 All servers have the same configuration. MySqlRouter is configured with a metadata-cache ttl = 1 second

 

How to repeat:

 Several Mysqlrouter client ...

Suggested fix:

 The request to get the cluster member list (with 3 JOIN in SQL request) seems to impact the load average. 

 These data doesn't change a lot (so requesting every second is not pertinent). But looking for PRIMARY node every second is pertinent.

 Why not having two different ttl (one for nodes list and another for node state) ?
[30 Aug 2019 6:34] MySQL Verification Team
Hello david deman,

Thank you for the report.

regards,
Umesh
[24 Jul 2021 10:43] k n
I've also encountered mysqlrouter with high cpu usage on the primary node of the cluster. The other nodes seem to be ok but I'm at the point I've had to stop using mysql router.  Is anybody able to fix this?