Campaign Delivery Logs not being deleted?

Lakjin

Active Member
In Backend -> Settings -> Cron I have "Delete campaign delivery logs" set to "Yes", but for some reason campaign delivery logs have not been deleted for more than 8 months. Any idea what is going on? I checked crontab, all the crons are listed there. I also checked cron job history in the backend. None have an error.
 
In Backend -> Settings -> Cron I have "Delete campaign delivery logs" set to "Yes", but for some reason campaign delivery logs have not been deleted for more than 8 months. Any idea what is going on? I checked crontab, all the crons are listed there. I also checked cron job history in the backend. None have an error.
Can you check if you don't have changed days back to delete delivery logs? This can be changed by adding in apps/common/config/main-custom.php param: 'campaign.delivery.logs.delete.days_back' => 30.
If you click on Delete campaign delivery logs dropdown in that popup info how many days are indicated ?

Screenshot 2023-11-27 at 10.20.14.png
 
Can you check if you don't have changed days back to delete delivery logs? This can be changed by adding in apps/common/config/main-custom.php param: 'campaign.delivery.logs.delete.days_back' => 30.
If you click on Delete campaign delivery logs dropdown in that popup info how many days are indicated ?

View attachment 19356
I have not changed it, and it shows 30 days in the drop down
 
I have not changed it, and it shows 30 days in the drop down
Please try to run manually this command: delete-campaign-delivery-logs from command line and check if something is going wrong? Please follow this article to run command: https://www.mailwizz.com/kb/debug-send-campaigns-command/ but instead: send-campaigns type delete-campaign-delivery-logs with --verbose=1 flag to get output in terminal.
 
It ran, it deleted some logs, but then it stopped:

[2023-11-28 05:23:14] - Loading 50 campaigns to delete their delivery logs...
[2023-11-28 05:23:14] - Processing campaign with ID 15633 which finished at 10/29/23, 4:18 AM
[2023-11-28 05:23:16] - The count for campaign with ID 15633 is 388869.
[2023-11-28 05:23:16] - Updating the columns for the campaign with ID 15633...
[2023-11-28 05:23:16] - Deleting the delivery logs for the campaign with ID 15633...
[2023-11-28 05:24:57] - Processing the campaign with ID 15633 finished successfully.

[2023-11-28 05:24:57] - Processing campaign with ID 15634 which finished at 10/29/23, 3:10 PM
[2023-11-28 05:24:58] - The count for campaign with ID 15634 is 121442.
[2023-11-28 05:24:58] - Updating the columns for the campaign with ID 15634...
[2023-11-28 05:24:58] - Deleting the delivery logs for the campaign with ID 15634...
[2023-11-28 05:25:06] - Processing the campaign with ID 15634 finished successfully.

[2023-11-28 05:25:06] - Processing campaign with ID 15635 which finished at 10/29/23, 3:21 AM
[2023-11-28 05:25:06] - The count for campaign with ID 15635 is 49818.
[2023-11-28 05:25:06] - Updating the columns for the campaign with ID 15635...
[2023-11-28 05:25:06] - Deleting the delivery logs for the campaign with ID 15635...
[2023-11-28 05:25:09] - Processing the campaign with ID 15635 finished successfully.

[2023-11-28 05:25:09] - Loading 50 campaigns to delete their delivery logs...
[2023-11-28 05:25:09] - No campaign found for deleting its delivery logs!
[2023-11-28 05:25:09] - Done!
 
As i can see seems that this command is finished, last message show that not found campaigns to delete logs. Can you check if have another campaigns for which this command don't clear delivery logs ?
 
Maybe they're for autoresponders, which never get deleted.
No, they are definitely campaigns. I checked. We also dont have autoresponders.

Although now that I look into it, it looks like it isn't that many campaigns that haven't been deleted. There is one from February, one from March, and one from May. The rest of the logs are for campaigns within the past 30 days.

Any idea why the three from Feb/March/May have not been deleted? And how can I safely delete them? Can I just nuke the rows in the delivery log table?
 
Any idea why the three from Feb/March/May have not been deleted? And how can I safely delete them? Can I just nuke the rows in the delivery log table?
Can you open support ticket and give us access to your app in order to check this?
 
Can I just nuke the rows in the delivery log table?
ONLY if all your campaigns are sent, otherwise MailWizz will not know and will start sending to subscribers already received those emails.
Also, keep in mind, doing this will result in campaigns not having their stats saved.
You can pause sending for a few days till those stats are saved(5 by default), then empty the table.
 
Thanks guys, I went ahead and manually deleted the old campaigns that for whatever reason where not deleted.

Question. Does the "Delivery servers logs removal days" option in the backend not control when campaign delivery logs are deleted?
 
Delivery servers logs removal days
These relate to a different type of logs, logs for your delivery servers which we use to calculate usage quota, etc. Different things. By default we keep those for 90 days, if you don't care about quota for delivery servers, you can keep them for shorter periods of time.
 
Back
Top