1 (edited by Mr.TW 2021-04-14 19:30:31)

Topic: sogo_cache_folder database table growing fast

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.2
- Deployed with iRedMail Easy or the downloadable installer? no
- Linux/BSD distribution name and version: Ubuntu16 LTS
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): PGSQL
- 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.
====
Hi dear people outside,

we have trouble with our postgresql Database in combination with sogo.
The Database table 'sogo_cache_folder' is growing strongly.
the partition has not grown in recent years.

But now from 10 GB to 150GB in a few days.

sogo=# SELECT pg_size_pretty( pg_total_relation_size('sogo_cache_folder') );
pg_size_pretty
----------------
156 GB
(1 row)

How can we identify which datatype and kind is this? Do we need this cache data?

Best wishes
Vincent

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: sogo_cache_folder database table growing fast

iredmail support solved the issue (nice job thanks smile )

if you get these problem you can upgrade your sogo version from 4 to 5.

But the problem is coming up because something wrong in postgresql:

clearing the sogo_cache_folder is needed:
*) Stop sogo service for a while.
*) Take a fresh backup of `sogo_cache_folder` table
*) Drop sql table `sogo_cache_folder`
*) Recreate and restore `sogo_cache_folder` table.


Additionally you must set some postgresql configuration:
track_counts = on
autovacuum = on
autovacuum_max_workers = 3
autovacuum_naptime = 1min
autovacuum_vacuum_scale_factor = 0.002
autovacuum_analyze_scale_factor = 0.001

regards
vincent