MySQL/MariaDB Slow Query Log Visualizer

I have made a tool where you can load a MySQL slow query log file and use the various options to get further information. I forked a project that had been dormant for a while and have spent a lot of time reworking all of the code, updating libraries and improving functionality. I might make this part of a larger toolkit if I have the need for analysing other logs (eg Apache access logs).

The data is all processed locally and never leaves your browser or PC.

Everything should work but I am planning to tidy up the styling.

feedback is welcome and so are GitHub issues.

GitHub

Live Website

2 Likes

might seem a really daft question: but what is its purpose? / why/when to use it. and presumably ok for MariaDB as well?

your mysql server keeps crashing because it has run out of ram. This tool will help you find SQL queries that are taking to long to complete, and therefore more RAM and could be a cause of the service crashing.

1 Like

I have not tested this on a recent version of MySQL, but only MariaDB. I am hoping the formats are the same.

I might rename this app.

After using your code there maybe some ways to improve it

  • add the ability to upload a file rather than drag and drop
  • add the ability to choose a file from the local file system, which would allow users with a headless system to define the file rather then logging in to to the server from somewhere else that has a gui in order to drag and drop
  • alter the graphing if only a few hours are available as the graph looks odd in those circumstances

other than that it does what it says on the tin

add the ability to upload a file rather than drag and drop

I might add this.

alter the graphing if only a few hours are available as the graph looks odd in those circumstances

This on some of the graphs was a trade off to use the automatic label generation but not have too many labels. My demo file is very small, if you try it with a larger file you might see different results.

thanks for the feedback.

There was a lot of entries over a short period of time .. I have left my test mysql server logging data for a longer period to see what happens

I guess your not going to support implementations on a headless servers then oh well that would be a bit of a deal breaker for someone who uses a vps and/or virtualmin/webmin

What is need to pipe a system file to the app?

Just a file picker? Browse button?

If the system is headless, how can you use a browser?

That’s like saying that webmin/virtualmin doesn’t work on headless systems, which it does, and in fact manipulates the local file system and returns results to a browser located on a remote machine. A file picker is great if the data is located on the machine that the browser is located but when the data is located on a server in a data centre your either having to download the file then pass it back to the app (which could be located on the same server in a data centre) or log into the remote server using a file manager such as nemo or nautilus (I guess the windows file manager does this as well, it’s been over 20 years since I used that file manager) and use the drag and drop facility. It just makes it a bit clunky to use, not impossible but maybe more difficult than it should be.
N.B virtualmin file manager doesn’t appear to support drag and drop so you can not use that either

did when I last used it :grin:

that’s the other way around I want to drag a file from the file manager & not to it

1 Like

The browser must run on the system the file is located at.

don’t worry I’ll fork your code & fix it myself

on the dropdown list (of the vertical dots) adjacent to the check box the option to download will download the file - but I do not know how to “drag and drop” multiple files - perhaps a blue sky idea - but not had the need :man_shrugging:
and would probably just FTP it

In this instance with @shoulders app the slow query log needs to dropped into the app so to use the app I need to download the slow query log so I can drag and drop it to the app which is located on the server I just downloaded the log file from

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.