Skip to content
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

Server components not listening to ipv4 (ipv6 compatability issue) #772

Open
B-X-M opened this issue Jun 13, 2023 · 3 comments
Open

Server components not listening to ipv4 (ipv6 compatability issue) #772

B-X-M opened this issue Jun 13, 2023 · 3 comments

Comments

@B-X-M
Copy link

B-X-M commented Jun 13, 2023

With the introduction of ipv6 support, the server components (smp and xftp) do not listen to ipv4 any more. The server components bind to their respective ports on ipv6, but not on ipv4. If ipv6 is disabled on the server, the smp and xftp components fail to start. In my tests the last fully working smp-server version is v4.4.1. I suspect, it's some kind of regression with ipv6 support.

@epoberezkin
Copy link
Member

The way it works on most linuxes is that binding to ipv6 interface binds to both, so it's not a regression.

We don't bind separately to avoid having two separate threads separately binding to ipv6 and to ipv4.

I guess we just need a fallback that if binding to ipv6 failed or if it's not available then bind to ipv4.

What exactly gets printed when you start the server when ipv6 is disabled?

@B-X-M
Copy link
Author

B-X-M commented Jun 14, 2023

Thanks for your swift reply.

If ipv6 is disabled, the smp server prints:

Jun 14 11:42:23 (redacted) smp-server[7263]: smp-server: Network.Socket.socket: unsupported operation (Address family not supported by protocol)

and exits with status 1/FAILURE

If ipv6 is enabled, it starts, however it does bind only to ipv6. IPv4 connectivity is not present. "lsof -i" list just one entry:
smp-server 1008 smp 40u IPv6 26663 0t0 TCP *:5223 (LISTEN)

v4.4.1 works flawlessly...
Any ideas?

@B-X-M
Copy link
Author

B-X-M commented Jun 14, 2023

Sorry, the ipv6 issue was due to some silly FW misconfig. But the server crash on ipv4 disabled remains...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants