Work-around for the federation bug found in 0.19.0 and 0.19.1

walden@sub.wetshaving.social to Lemmy@lemmy.ml – 56 points –

I've found the following work-around works pretty well. If you host an instance that's currently on 0.19.0 or 0.19.1, consider implementing this.

There are two bugs that this helps with:

Work-around:
Create cronjobs that restart the Lemmy container every 6 hours (but not at midnight). The following example is used for a Debian system running Lemmy in Docker.

Type crontab -e into the terminal Add something like the following:

0 1 * * * docker container restart lemmy-lemmy-1
0 7 * * * docker container restart lemmy-lemmy-1
0 13 * * * docker container restart lemmy-lemmy-1
0 19 * * * docker container restart lemmy-lemmy-1

3 1-23/6 * * * docker container restart lemmy-postgres-1 && sleep 60 && docker container restart lemmy-lemmy-1

By restarting the container every 6 hours, outbound federation continues to work. There may still be some delays, but everything gets cleared up regularly.

By telling it what time to restart (0100, 0700, 1300, and 1900 as opposed to "every 6 hours"), it avoids restarting at midnight. This avoids the second bug.

My instance has been doing this for enough days where I'm confident that it's working. You can check your federation status here. Note that it's normal for there to be 0 up-to-date instances and a lot of lagging instances. As long as they sometimes turn "up to date", then everything is getting caught up.

13

I like to do things just off the top of the hour, since top of the hour is when many maintenance crons run. If you're running a modern cron daemon, you can rewrite that as:

3 1-23/6 * * * docker container restart lemmy-lemmy-1

https://crontab.guru/#3_1/6___*

The only thing that doesn't seem to federate on my 0.19.1 instance is new subscriptions, but in saying that it looks like the BE restarted an hour ago

Funnily enough, since I've started to regularly check if my comments made it out I haven't had any problems. Schrödinger's bug.

Edit: Then again, after checking with this post, although my comment made it out just fine, some comments haven't arrived on my instance. I'll try to restart.

Comments from other instances should arrive to yours no problem, as the bug only seems to affect outgoing stuff. If the other instance is running 0.19.0+, then of course those comments might be stuck.

Why are you fuckers so keen on updating to 0.19 so quickly anyway? My instance hasn't and they probably won't for a long time. Ya'll idiots did it to yourselves by going "Ooh shiny new lemmy version, Imma update immediately on day 1" this is why this is such a widespread problem. Why does it surprise me that the owners of woke instances don't understand this shit.

Downvote me all you want assholes but you know I'm right.

Because it offers new features to immature software still in development.

It gives snowflakes like yourself the ability to block woke instances so your limited brain capacity isn't overwhelmed. It also gives scaled sort, the ability to see niche sub's with less content higher up, so you can see the latest content from your favourite country music communities or about the latest NASCAR race in which people take the same turn constantly for hours on end rly fast.

Dat's some good shizz and worth updating for, surely?

Gotta love those communists that build Lemmy and give you this much joy. That do the hard stuff like running updates and testing so anyone of any (limited) ability can enjoy :).

Why does it surprise me that the owners of woke instances don’t understand this shit.

Wow, just wow. I'm pretty sure you must know this, but since you seem to have some sort of selective amnesia, let me break it down for your stupid ass. Lemmy follows the semantic versioning, meaning that 0.19.1 can be seen as:

  • 0: the major version
  • 19: the minor version
  • 1: the patch version

Why are you fuckers so keen on updating to 0.19 so quickly anyway?

Lemmy is still in the major version 0, and not 1. Meaning that it is still in alpha, and hasn't reached the stable version 1.x.y. Go and read the SemVar FAQ first.

Every user on this platform is an early adopter, and consists of developers and geeks. Also, the Lemmy devs run lemmy.ml.

My instance hasn’t and they probably won’t for a long time.

And? What are we supposed to do with this information?

Your comment adds no value to a productive discussion. Shush away.

My instance still has working federation while many are either partly or completely borked. That's the takeaway.

Shush away.

Oh no, I've been shushed, whatever shall I do now that the sissy little snowflake told me to shush. I guess I have no choice but to listen to some random Lemmy user who has no authority over me or my choices, JK I don't answer to you. I'm just gonna block you lmao

Downvoted out of spite for that last line. I mean come on, it was 1 downvote.

EDIT: Oh you're the owner of sh.itholefor.nazis? Cool, please instance ban me. I am sick of your shitty users constantly leaving harassing comments and downvote barraging anything left of hitler and would rather your users just not see my comments. Thanks, and GFYS.