Does RT start threshing if mysql has a problem


We are running RT 3.2.2 with Apache 2.0.52, mod_perl, and MySQL 4.10 on FreeBSD 4.10.

Over the wkend, RT showed that it created about half dozen tickets for the same new request submitted by a user via email. This morning, RT web interface is not working all.

I logged on the rt server (where mysql resides as well). ‘top’ showed mysql is at 100% cpu. Since my priority was to get RT back online asap, I simply bounced mysql and RT without trying to figure out why mysql was going crazy. Everything seemed to be back to normal after the bounce.

During the post-mortem investigation, the user confirmed that he only sumbitted the new request via email once over the wkend. There is no reason to think he is BSing me, so I suspect that RT has some logic of trying to create the same ticket many times if the db is slow/hanging. Can anyone shed some light on this?



It’s possible a long or infinite loop was hit trying to create the ticket
and the REST API or something between (and including) sendmail and RT hit a
timeout and retried. A few things come to mind:

  1. Is the message-id in all the duplicate tickets the same (view full
    headers inside the RT web interface). If it’s the same, the email was not
    re-submitted. If they ARE different, the resubmission likely occurred
    OUTSIDE your sendmail/RT instance. Fully parsing the headers to find out
    where/how would be in order.

  2. If this happens again, use “show processlist” inside MySQL so you can
    find out what query (or queries) was running and chewing CPU - that would
    give a lot of insight towards the issues.

  3. You might want to turn on slow query logging (MySQL /etc/my.cnf option)

Hope that helps,

-=| Ben