getumbrel / umbrel-os

umbrelOS for Raspberry Pi 4 (only). Covert your Raspberry Pi into a home server in one click. For other hardware, checkout https://github.com/getumbrel/umbrel
https://umbrel.com
BSD 3-Clause "New" or "Revised" License
590 stars 55 forks source link

Disable IPv6 in Avahi #99

Closed mayankchhabra closed 4 years ago

mayankchhabra commented 4 years ago

Fixes #76

Further reading: Hostname changes with appending incrementing numbers

nolim1t commented 4 years ago

The other method of binding to the interfaces works too. Disabling ipv6 means it would break on an ipv6 network

mayankchhabra commented 4 years ago

Binding interfaces seems to have mixed reviews:

image

Disabling ipv6 means it would break on an ipv6 network

Oh, I don't know if there were IPv6-only networks as well? Don't routers support both IPv4 and IPv6?

nolim1t commented 4 years ago

Binding interfaces seems to have mixed reviews: the patch worked for me.

Disabling ipv6 means it would break on an ipv6 network

Oh, I don't know if there were IPv6-only networks as well? Don't routers support both IPv4 and IPv6?

https://en.wikipedia.org/wiki/World_IPv6_Day_and_World_IPv6_Launch_Day

mayankchhabra commented 4 years ago

What am I supposed to conclude from that? 🤔

IPv6 traffic on AMS-IX was measured by ether type distribution as 0.4 percent, while IPv4 was measured as 99.6 percent on average in both daily and weekly graphs.

mayankchhabra commented 4 years ago

the patch worked for me.

Also what are the steps you used to reproduce the issue and test your patch? I'd like to test too as I sometimes encounter the same bug, but can't reproduce manually.

nolim1t commented 4 years ago

Also what are the steps you used to reproduce the issue and test your patch? I'd like to test too as I sometimes encounter the same bug, but can't reproduce manually.

Fetch the new file then copy it and restart avahi-daemon.

mayankchhabra commented 4 years ago

How to reproduce the issue?

nolim1t commented 4 years ago

just use avahi as default settings and actually leave your box on for a prolonged period of time

AaronDewes commented 4 years ago

I don't know if you knew, but there is a fix for the avahi source code that isn't merged yet. Maybe you could add a custom prebuilt avahi which fixes the issue to umbrel.

https://github.com/lathiat/avahi/commit/0a536f6082037d07ceae1404e95fec7cd40ff20c

mayankchhabra commented 4 years ago

Whoa @AaronDewes, wasn't aware of it! You're ahead of the game as always ;)

Two quick questions though:

mayankchhabra commented 4 years ago

Fetch the new file then copy it and restart avahi-daemon.

@nolim1t if you restart avahi-daemon while facing the bug even without changing the config file, it will still fix it automatically. So I'm not sure there's any real way to test it other than just wait and watch. :|

nolim1t commented 4 years ago

Fetch the new file then copy it and restart avahi-daemon.

@nolim1t if you restart avahi-daemon while facing the bug even without changing the config file, it will still fix it automatically. So I'm not sure there's any real way to test it other than just wait and watch. :|

it will happen over time.. just run your node as per normal and remember the TOR ssh address or have a keyboard and monitory ready. Not all things can happen immediately

AaronDewes commented 4 years ago

Why hasn't this been merged (if you know)?

It has not been tested enough yet, because the problem is often hard to reproduce.

Also, how will the maintainability be impacted if we use a custom package? I think we'll have to manually build avahi everytime it's updated?

Yes, but I think you could use github actions to build.

mayankchhabra commented 4 years ago

Closed in favor of binding interfaces (#80). If the issue still persists, we can look into disabling IPv6 or using a custom Avahi build based on https://github.com/lathiat/avahi/commit/0a536f6082037d07ceae1404e95fec7cd40ff20c.