As a matter of interest, we were having performance issues on our os ticket instance running on IIS / MySQL.
We upgraded to MariaDB and was working fine, however when the site came under load the MariaDB instance took CPU to over 100% on all cores (even after upgrading to 20vCPU).
Did some digging and analysis, and after adding the below two indexes, CPU dropped to 20%.
OsTicket running incredibly quicker on MariaDB now.
-- ALTER TABLE ost_thread
ADD INDEX ost_thread_idx_object_type_object_id
(object_type
,object_id
);
-- ALTER TABLE ost_thread_referral
ADD INDEX ost_thread_referra_idx_object_type_thread_id
(object_type
,thread_id
);
Perhaps there are more ways we could improve performance by tweaking additional indexes?