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

SO_REUSEPORT has gone from unix_impl #41

Closed
stgleb opened this issue Jan 29, 2018 · 2 comments
Closed

SO_REUSEPORT has gone from unix_impl #41

stgleb opened this issue Jan 29, 2018 · 2 comments

Comments

@stgleb
Copy link

stgleb commented Jan 29, 2018

Operating system linux

Looks like constant SO_REUSEPORT has gone from linux impl.

libp2p/go-reuseport/impl_unix.go:47:51: undefined: unix.SO_REUSEPORT

@stgleb stgleb closed this as completed Jan 29, 2018
@Stebalien
Copy link
Member

(I assume you've updated golang.org/x/sys/unix)

@hayarobi
Copy link

hayarobi commented Jul 3, 2018

The constant SO_REUSEPORT is still missing in Linux/386 and amd64. https://github.com/golang/go/issues/23696

Here is my Ubuntu system. I check go-1.10 and go-1.9.
adm@ubuntu1604:/usr/lib/go-1.10/src$ uname -a
Linux ubuntu1604 4.4.0-128-generic #154-Ubuntu SMP Fri May 25 14:15:18 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

adm@ubuntu1604:/usr/lib/go-1.10/src$ grep -R SO_REUSEPORT * | sort
net/net_test.go: // enabling SO_REUSEPORT option such as Linux,
net/sockopt_bsd.go: return os.NewSyscallError("setsockopt", syscall.SetsockoptInt(s, syscall.SOL_SOCKET, syscall.SO_REUSEPORT, 1))
syscall/net_nacl.go: SO_REUSEPORT
syscall/zerrors_darwin_386.go: SO_REUSEPORT = 0x200
syscall/zerrors_darwin_amd64.go: SO_REUSEPORT = 0x200
syscall/zerrors_darwin_arm64.go: SO_REUSEPORT = 0x200
syscall/zerrors_darwin_arm.go: SO_REUSEPORT = 0x200
syscall/zerrors_dragonfly_amd64.go: SO_REUSEPORT = 0x200
syscall/zerrors_freebsd_386.go: SO_REUSEPORT = 0x200
syscall/zerrors_freebsd_amd64.go: SO_REUSEPORT = 0x200
syscall/zerrors_freebsd_arm.go: SO_REUSEPORT = 0x200
syscall/zerrors_linux_arm64.go: SO_REUSEPORT = 0xf
syscall/zerrors_linux_mips64.go: SO_REUSEPORT = 0x200
syscall/zerrors_linux_mips64le.go: SO_REUSEPORT = 0x200
syscall/zerrors_linux_mips.go: SO_REUSEPORT = 0x200
syscall/zerrors_linux_mipsle.go: SO_REUSEPORT = 0x200
syscall/zerrors_linux_ppc64.go: SO_REUSEPORT = 0xf
syscall/zerrors_linux_ppc64le.go: SO_REUSEPORT = 0xf
syscall/zerrors_linux_s390x.go: SO_REUSEPORT = 0xf
syscall/zerrors_netbsd_386.go: SO_REUSEPORT = 0x200
syscall/zerrors_netbsd_amd64.go: SO_REUSEPORT = 0x200
syscall/zerrors_netbsd_arm.go: SO_REUSEPORT = 0x200
syscall/zerrors_openbsd_386.go: SO_REUSEPORT = 0x200
syscall/zerrors_openbsd_amd64.go: SO_REUSEPORT = 0x200
syscall/zerrors_openbsd_arm.go: SO_REUSEPORT = 0x200

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

3 participants