What is the long-term storage plan for Lemmy instances?

Kalcifer@lemmy.world to Lemmy@lemmy.ml – 168 points –

Over time, Lemmy instances are going to keep aquiring more, and more data. Even if, in the best case, they are not caching content and they are just storing the data posted to communities local to the server, there will still be a virtually limitless growth in server storage requirements. Eventually, it may get to a point where it is no longer economically feesible to host all of the infrastructure to keep expanding the server's storage. What happens at this point? Will servers begin to periodically purge old content? I have concerns that there will be a permanent horizon (as Lemmy becomes more popular, the rate of growth in storage requirements will also increase, thereby reducing the distance to this horizon) over which old -- and still very useful -- data will cease to exist. Is there any plan to archive this old data?

82

You are viewing a single comment

The largest table holds data that is only needed by Lemmy briefly. There is a scheduled job to clear it... Every 6 months. There are active discussions on how best to handle this.

On my instance I've set a cronjob to delete everything but the most recent 100k rows of that table every hour.

I saw that issue, and then I saw people having problems after clearing it, so I'm just going to wait until they figure that out in a stable version. Looking forward to it though!

@ubergeek77@lemmy.ubergeek77.chat @lodion@aussie.zone Can either of you link to that discussion please?

It looks like the issue I was referring to has since been edited, as it's not actually relevant to clearing this database bloat:

https://github.com/LemmyNet/lemmy/issues/3103

I mean, that post is exactly about clearing database bloat. The bulk of the bloat is in the activity table (going by the comments in the thread).

Yeah, I meant the comments that have been hidden previously made it seem like clearing it would be an issue, so I hesitated to clear it. Now that those comments have been edited, it looks like it won't break anything after all.