-
-
Notifications
You must be signed in to change notification settings - Fork 15.5k
Various software refuses to bind to it's listenaddress #71106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
are you running any large server workloads on this box? First thing I was thining of is that perhaps your file descriptor pool is exhausted? |
Could you show the output of |
Nope, one of the machines is my laptop with few services.
Sure! trace.txt At least for |
Thanks. could you also show the output of From the logs it seems like your loopback interface is not available (which is odd)
|
Sure 😄
Worth noting, I do use |
In that case, a |
As requested. Note that I removed the
|
Looks like the loopback interface has lost its configuration as it doesn't have any addresses. This sounds like the same issue as I reported here. |
@alexbakker Ah yes! |
That
here?
For you to get further and not have a buggy experience, I advice to make |
@arianvp Sure!
Many thanks for the information, this makes sence. |
Interesting. Could you show your as per release notes:
The origianl PR: |
I have experienced the cc @fpletz |
Sure!
So looks like it is my fault, as I have DHCP=yes. Would you mind sharing a basic idiomatic sample for a systemd-networkd config? |
Should do the job in your case. Explicitly only match interfaces for which you want to actually do DHCP. Or you could add
Both will work. One is blacklist based, the other whitelist based. Note that we'll probably move to a model where all interfaces are |
I was looking to see if this is a systemd bug, but this behaviour is documented. It's not a bug. From the
The linux kernel brings Another way to fix this would be to have an explicit configuration for
|
I would personally much rather have the option to have networkd not touch any network interfaces by default, except for the ones that have a config in |
Agreed. That is the option we're planning to implement soon. (See @globin 's reaciton) |
Issue is solved by #71106 (comment), thank you all! |
Just maching all network interfaces caused many breakages, see NixOS#18962 and NixOS#71106. We already don't support the global networking.useDHCP, networking.defaultGateway(6) options if networking.useNetworkd is enabled, but direct users to configure the per-device networking.interfaces.<name?>.… options.
This is a weird bug. When a service is changed during
nixos-rebuild
and therefore restarted, it refuses to bind to it's given port. For Example:Though nothing is listening on that port:
I have this problem with all kind of services, for example
mpd
. Even a local build ofzola
(a static site generator with a preview function) doesn't start at this point:Changing the port in question doesn't change anything.
The symptomatics is always the same: according to
ss
the port is not in use yet the software claims that it cannot bind to the port. I'm desperate for input on how to debug this.Edit 1:
After a fresh restart, things (
zola serve
) work! Then, afternixos-rebuild test
, things (zola serve
) still work. So, I still don't know how to reproduce this reliable.Edit 2:
After a
systemctl suspend
, things (zola serve
) won't work.Expected behavior
Service starts listening on it's assigned and free port
Additional context
I've encountered this on two of my machines, one with linux 4 and one with linux 5
Metadata
"x86_64-linux"
Linux 5.3.5, NixOS, 19.09.789.7952807791d (Loris)
yes
yes
nix-env (Nix) 2.3
"nixos-19.09.789.7952807791d, nixos-unstable-20.03pre197080.dd050270c78"
"nixos-unstable-20.03pre196480.8b46dcb3db5"
/nix/var/nix/profiles/per-user/root/channels/nixos
The text was updated successfully, but these errors were encountered: