That’s very strange as the configuration, hardware configuration and of course the monitoring stats look perfectly fine (mine don’t look any worse or better). Until now I always blamed the vHost of my Hosting provider whenever a small delay came.
To be honest until now I didn’t really bother, but when you have to work exessive with it, I can understand that this is really troublesome.
What’s the version of elasticsearch and zammad btw?
it seems that you are facing with different issues.
1) 100% cpu time
This seems to be the Zammad scheduler -> this has changed in Zammad 2.4 - the scheduler will use much less cpu time
2) Sporadic delays (e. g. 20 sec.)
Per default Zammad starts with one application server process (with max. 30 threats). If you have several concurrent users it may not be enough (http requests will get queued which leads to high latency). Depending on you need you can start more processes (each with max. 30 threads). Just do the following for 4 application server processes:
Please note, that each application server process needs memory (just have a look on it that the machine is not swapping). Hint: In case you use elasticsearch on same machine, take about 6 GB RAM for elasticsearch it self (it’s not Zammad related).
You will get a noticeable improvement if you use an ramdisk for the /opt/zammad/tmp directory.
To test this, just enter the following for an 8 GB ramdisk (temporary ramdisk):
Imho instead fiddling around with tmpfs we should give memcached a try as described in: https://github.com/zammad/zammad/issues/1601
If its run on the same server as zammad a unix socket could be used so that there is no additional network latency added.
Maybe even the existing POC of rabbitmq could be helpful.
Is there a way to monitor the usage of application server process/threats.
How many processes/threats are used/free.
Sometimes we have sporadic delays, and I don’t know how many of my processes/threats are in use/free.
now we run WEB_CONCURRENCY=2.
Is there a way to Monitor the usage of zammad processes and threats.
I hope that I can figure out the right value for WEB_CONCURRENCY.