There is always going to be some amount of time that it takes to open a ticket.
Here's what happens when a ticket is opened and where slow down can occur:
- the database gets updated (creates the various entries in several tables to make a ticket a ticket)
- an email gets sent. This means that the UI pauses while it makes sure that the
While you can just read the short version below, I would urge you to read the TLDR version. Sorry it is so long.
Here are some possible fixes:
Short version:
- faster hardware
- faster internet connection
- more resources to PHP and MySQL
- setup a local mail relay
TLDR version:
Let me start by saying that you will need to invest some time and energy in finding the actual bottleneck. This should get you started. Nothing should be 'optimized' before we know what the cause is.
I think that the slowness that you are experiencing is due to mostly latency between the web server and the mail server and that the pause is longer because of how long it takes to send and receive the data between the two. While upgrading your hardware, or upgrading your internet speed could result in better times I do not know if your web server is hosted internally or externally. I can tell from your screen shot that your mail server is hosted externally (looks like Barracuda Networks). If you can open a command line on your webserver you could do a traceroute from web to mail and see how many hops it is and what the average times are. You could try to run a continuous ping for a while and see what the avg time is. note: some mail servers do not answer ICMP (ping) so this one might now work. If they do not then you would likely have to contact Barracuda mail server support and see if they would be willing to do it in the reverse direction.
If you can some how reduce the latency between the web server (fast hardware might help) to Barracuda (faster internet might help) or even eliminate the latency altogether that should help. If you can setup an internal SMTP relay [such as on your web server, or on a server next to the web server] this would tell us better if its a latency issue. Since it only takes a couple of minutes to set one up I would give that a try and see what your ticket open times are after that using the relay.
When we setup ours we made it only capable of receiving email from our domain, and specific machines on our domain. We have not had any spam problems due to it yet /knocksOnWood.
You can turn on MySQL slow query logs (wait a bit and then look at them). If you have queries that are taking too long to run then this will tell you that your MySQL needs more resources. This can mean allocating more RAM to the processes, and/or faster bigger hardware. You could also Try using MariaDB instead of MySQL. This would mean installing and configuring MariaDB, migrating a copy of your database over to it and then creating a test environment website and cloning your osTicket to it, then the test sites osTicket at the new database (in MariaDB).
PHP is also a potential bottleneck. While you may be tempted to increase the memory_limit directive you should not unless you have scripts hitting the limit and erroring out by hitting that limit. This would be logged to your PHP error logs. The default setting is likely fine. I should also mention newer versions of PHP are much faster than older versions. The speed increase from 5.6 to 7 is very impressive. I know that you are running some version of PHP7, but it is worth mentioning to be thorough.
Faster and bigger hardware can help. I find it unlikely that this is your bottle neck based on the information that you have provided at this time. My 2 live osTicket and 2 test osTicket sites and MySQL run on a Windows 202 R2 server under IIS on a Virtual Machine with 2 processors (2 cores each) each processor is 2.67Ghz with 12GB of RAM. The web server also has MyQL databases for several other applications and are running 14 websites. 5 of those sites are a multisite Wordpress implementation. So if your hardware is close to mine, and your only running a single osTicket site then upgrading your hardware will not help.
(This is also only mentioned for thoroughness) The webserver software and OS. You would have to do some serious research and testing but you could compare Linux/Apache vs Windows/Apache vs Windows/IIS environments to see which one performs the best in your use case. I do realize that some companies just won't do this or cannot do this based on orders from on high.