"are you suggesting to define the second index with the 3 fields? " -- yes:
ALTER TABLE stats_sit
ADD INDEX(matrixID, agg_time, end_time);
"As for the stats_filesystem, there is no where cause there is one line.
Is that a problem?" -- Eh? I see a WHERE clause. Are you saying there is only one line in the table? If so, then the presence/absence of a WHERE clause makes no difference (unless the WHERE clause does not match the one row).
Quote
As for the alerts-links, what do you mean by:
Ouch! There is nothing tying the two table together! ??
Are you referring to a foreign key not defined between them?
You must still tie the two tables together with a WHERE clause or (better) a ON clause. Otherwise, you get a 'cross join', which is orders of magnitude slower than what you expect.