Remove all items older x days

Hello Forum,

we got quite a big db in our Company (158GB whole db folder using innoDB on Mariadb(mysql)-5.5.56).
We also got an archive-system with all messages saved in there.
my question:

is there a way (maybe python etc) to delete all messages older than x days? - not just softdeleted items, but all
after that i would use “mysqlcheck --all-databases --auto-repair --extended --optimize” to recreate the tables.
Just tested on my test-env and this worked with purgeing softdeleted items.

thanks in advance

Coffee_is_life

CentOS 7.4.1708
Mariadb-5.5.56-2
KC 8.5.4.0-9.1
WebApp 3.4.5.1202-47.1 external Server - TCP-Socket
Z-Push 2.3.9+0-90.1
PHP-MAPI 8.5.4.0-9.1
PHP 5.6.25 with Zend OPcache v7.0.6-dev
DeskApp 1.5.0
Outlook 2016(64bit) KOE 1.6.282
Outlook 2010 -Zarafa 7.2.6

hello again,

i’ve found a script in kopano-scripts called “delete-items.py” - seems to be my desired action.

coffee_is_life

CentOS 7.4.1708
Mariadb-5.5.56-2
KC 8.5.4.0-9.1
WebApp 3.4.5.1202-47.1 external Server - TCP-Socket
Z-Push 2.3.9+0-90.1
PHP-MAPI 8.5.4.0-9.1
PHP 5.6.25 with Zend OPcache v7.0.6-dev
DeskApp 1.5.0
Outlook 2016(64bit) KOE 1.6.282
Outlook 2010 -Zarafa 7.2.6

Log in to reply

Looks like your connection to Kopano Community Forum was lost, please wait while we try to reconnect.