Topic: way to long running query when loging in.
==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.6.5 OPENLDAP edition
- Deployed with iRedMail Easy or the downloadable installer? downloadable installer
- Linux/BSD distribution name and version: Ubuntu 22.04 LTS
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? Yes
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
We are having trouble with logins to iRedAdmin-Pro, a longrunning SQL querry runs into an timeout.
MariaDB [amavisd]> SELECT COUNT(msgs.mail_id) AS total -> FROM msgs -> LEFT JOIN msgrcpt ON (msgs.mail_id = msgrcpt.mail_id) -> LEFT JOIN maddr AS sender ON (msgs.sid = sender.id) -> LEFT JOIN maddr AS recip ON (msgrcpt.rid = recip.id) -> WHERE msgs.quar_type <> 'Q' AND recip.domain IN ('<LIST OF DOMAINS>') AND msgs.time_num > 1696837022 -> ; +-------+ | total | +-------+ | 3419 | +-------+ 1 row in set (47.928 sec)
we for now did a workaround by adding an uwsgi timeout to the nginx config:
uwsgi_param SCRIPT_NAME /iredadmin; uwsgi_read_timeout 600s; # Access control
As this is for us only a workaround, we would like to know how we could fix it.
----Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.