Skip to main content


 
So let's see how this works out:
// clean up the database
$a->config['system']['dbclean'] = true;
$a->config['system']['dbclean-expire-days'] = 600;

This setting should delete all public posts from other server with no user on my server owning them after 90 (??) days, that's the first setting.
The second setting should expire all external posts owned by some user locally.

I think #Friendica picked up to work on the cleanup and expiry this last hours, I can see 2000 open task in the queue.

I did this because the database was getting bigger and bigger an I heard other server do this as well, so when I read that my database is bigger than other public server database I started thinking.

#support
Dieser Beitrag wurde bearbeitet. (vor 3 Monate)
The queue stays around 2000, but posts (like this one) are delivered fast.

I guess the cleanup could be a bit lower priority/cause less load on the system if it was just activated.
I see it deletes batches of 1000 items.

From the log, a grep of "DBClean.php":
2018-04-10T03:52:13Z@wrk5acc308c562dd5.40710157 [NORMAL]:DBClean.php:334:removeOrphans Done deleting 1000 conversations. Last created: 2017-05-02 18:37:31
2018-04-10T03:52:18Z@wrk5acc34f2d9aff9.63383735 [NORMAL]:DBClean.php:318:removeOrphans Deleting old conversations. Last created: 2017-05-02 18:37:31
2018-04-10T03:52:21Z@wrk5acc34f2d9aff9.63383735 [NORMAL]:DBClean.php:324:removeOrphans found old conversations: 1000

The queue is not full anymore, so maybe the whole process already finished.

OK, not yet finished, still ongoing, but still the queue ist less full. I guess it will continue a few days, the database shrink by 200 MB sind this morning, I did not check the initial size.
Also I think the DB will shink much more from its current 35 GB for 2,75 years.

Wow, that really is going to be a little while.

Impressive, who did program the cleanup anyway? @Michael Vogel were you involved? Thanks for that feature.
Dieser Beitrag wurde bearbeitet. (vor 3 Monate)

So it did cleanup another 6 days over night, so I think 12h per 6 days, it is somewhere in may 2017 now, I assume it will slow down coming to closer to today as my server probably has received more and more messages per time.
That 6 days account for about 100 MB, very roughly.

Yeah, it was my work. Otherwise pirati.ca and squeet.me had already been dead.

It is now already running for a week, that is really impressive.

The main part of the feedback is "it works well, just activate the function and wait for it to finish".

Now we are about a month further again. Really amazing how this long lasting process is just going on and on and on....


Because it is my personal server, not other users on it, so I like the data to be available that long, for my public server I chose 365 days.

Oh and I was to lazy to calculate 2*365.

Done deleting 1000 conversations. Last created: 2017-07-20 12:54:39

It is going on and on and on... I am still impressed by this process.

Database size: 37,4 GiB

I did not yet optimize anything manually.

Now I got tagged... maybe it needed some time (cron calling the worker process)?

not on my side I think... the queue at them moment is empty and the work usually runs continuously, it is restarted 2 minutes after it quit, actually 2 minutes at most. I have systemd doing that.