Not sure how but is there a way to get basic metric data from MySQL. Show processlist list is a snap shot if now. But I was looking for average stats for a time frame. Last 10 minutes etc. I am using MySQL 8 on unbuntu 20

2 Answers 2


However, there are many issues. You need to, for example, know that Queries or Questions is a count of queries (in/out of stored procs) since the server was restarted. And that Uptime is in seconds. Hence, division is needed for "per second".

Dozens need that division; dozens are in bytes; dozens are in numbers (Max_used_connections)

But... That is only from start. To get the "last 10 minutes", you needed to have captured value(s) 10 minutes ago. That is not automatically available. Various monitoring services (many cost money) do that for you.

(The above information applies to all versions.)


Command STATUS; will return a brief summary for uptime and average q/s value. More comprehensive data returned by SHOW GLOBAL STATUS;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.