# Command mautic:maintenance:cleanup --days-old do not works

**URL:** <https://forum.mautic.org/t/command-mauticcleanup-days-old-do-not-works/35797>\
**Category:** Product Support\
**Tags:** mautic-4\
**Created:** [June 4, 2025, 3:58pm UTC](https://forum.mautic.org/t/command-mauticcleanup-days-old-do-not-works/35797 "2025-06-04T15:58:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![hromartins](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/hromartins/32/14082_2.png) [@hromartins](https://forum.mautic.org/u/hromartins)\
**Post date:** [June 4, 2025, 3:58pm UTC](https://forum.mautic.org/t/command-mauticcleanup-days-old-do-not-works/35797/1 "2025-06-04T15:58:09Z")

</div>

**Your software**  
My Mautic version is: v4.4.10  
My PHP version is: 7.4.33  
My Database type and version is: 10.11.8-MariaDB-ubu2204-log

**Your problem**

Hello everyone! I’m trying to perform a cleanup on my Mautic instance using the command `mautic:maintenance:cleanup --days-old=30` directly via SSH. Currently, if I run the command with `--dry-run`, it shows me the following records:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/9/9226d50a98babdb8009156647f333abb99e1cc65.png)

However, when I run the command again _without_ `--dry-run` (which should perform the cleanup), it quickly returns to the SSH command prompt. Then, if I use `--dry-run` again afterward, it displays the _same_ records as before, suggesting that the command didn’t actually work:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/3/3e002e72ab415ad6ec71040d8d161c0265d9520e.png)

_// path hidden for security reasons_

**Server info:**  
ARM, 5Ocpu, 25Gb RAM.

**Database info** :  
table\_name size\_MB  
email\_stats 6449.23  
page\_hits 1825.58  
audit\_log 442.72  
lead\_event\_log 407.33  
ip\_addresses 238.28

* * *

**Does anyone have a solution for this problem?"**

---

<div class="post-metadata">

**Author:** ![hromartins](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/hromartins/32/14082_2.png) [@hromartins](https://forum.mautic.org/u/hromartins)\
**Post date:** [June 4, 2025, 7:02pm UTC](https://forum.mautic.org/t/command-mauticcleanup-days-old-do-not-works/35797/2 "2025-06-04T19:02:11Z")

</div>

Hello everyone! I managed to solve the problem by changing the command input from `s` to `y`. Due to a translation issue (as you can see in the image, the system suggests s/n instead of y/n), the command wasn’t executing properly. With this change, I was able to successfully perform the cleanup.

**To all Brazilian users who may be facing this issue: this is the solution.**

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/1X/43c63600fe51440378769136903f1fa2a9a34102.png) [@system](https://forum.mautic.org/u/system)\
**Post date:** [June 6, 2025, 7:02am UTC](https://forum.mautic.org/t/command-mauticcleanup-days-old-do-not-works/35797/3 "2025-06-06T07:02:43Z")

</div>

This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.
