Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

osticket hang-up - performance issue

Using osticket 1.10

Sometimes osticket stop working, there is
no access to the panel possible. I have check the logs and found in the
mysql slow query log:
# Time: 161120 19:58:17
# User@Host: custcare[custcare] @ localhost []
# Query_time: 844.755410  Lock_time: 0.000116 Rows_sent: 3  Rows_examined: 227210
use custcare;
SET timestamp=1479668297;
SELECT A2.`id` AS `dept__id`, AVG(DATEDIFF(A1.`closed`, A1.`created`)) AS `ServiceTime`, AVG(DATEDIFF(A4.`created`, A5.`created`)) AS `ResponseTime` FROM `ost_ticket` A1 JOIN `ost_department` A2 ON (A1.`dept_id` = A2.`id`) LEFT JOIN `ost_thread` A3 ON (A3.`object_type` = 'T' AND A1.`ticket_id` = A3.`object_id`) LEFT JOIN `ost_thread_entry` A4 ON (A3.`id` = A4.`thread_id` AND A4.`type` = 'R') LEFT JOIN `ost_thread_entry` A5 ON (A4.`pid` = A5.`id`) WHERE A1.`dept_id` IN ('1', '4', '5') GROUP BY A2.`id`;
It seems to block all other processes. In mysql all other queries 'waiting for the table level lock'. Sometimes the query runs even longer as shown in the post above, sometimes until my server runs out of memory!

What can I do to prevent this hang-up?


  • Please help us to help you by reading and following the posting guidelines located in this thread: Please read before requesting assistance.  The more information you give us the better we will be able to assist you. Thank you.

    System environment information?
    How many tickets do you have?
    I ran that query on my 1.10 test system (which has bout 8k tickets) and the response is near instantaneous.
Sign In or Register to comment.