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
net, syscall: implement network interface API on Solaris #7177
Comments
This should provide the support for interfaces and addresses (sans Multicast for which there is a separate issue files). |
@postwait, we can't take patches that way. Everything that goes into one of the Go repos needs a CLA agreement. See https://golang.org/doc/contribute.html . That page is a wall of text, but it's easier than it looks. |
@bradfitz I just posted it here for other people to play with.... I already put it here as well.. |
CL https://golang.org/cl/29190 mentions this issue. |
One issue with the code is that it fails the net.TestInterfaces It would seem that the go code assumes that an ifindex on an interface uniquely refers to a set of properties on the interface. On Solaris... ifindex+family uniquely describe this. So, on my box there are two interfaces with ifindex: 1... one is IPv4 and the other is IPv6... the test fails because these two interfaces have different MTUs. I see two solution... fake an ifindex, or unbreak this uniqueness assumption. |
@mikioh, preferences? |
A "bad solution" but flexible is to have this make the ifindex's act as go_ifindex := (ifindex * 256) + family It would then be sparse, but allow for all families to be be uniquely indexed... It's a nasty approach though. |
Actually fudging the ifindex isn't useful. That test does a check by name as well. There are certainly two lo0's on my box... and they definitely have different MTUs. So, back to square one... almost need to simply annotate that the test assumptions aren't valid on Illumos/Solaris. |
Not so good at this Gerritt thing... super different workflow 👎 |
It grows on you. I can't do a Github code review these days. |
The latest change proposed skips the test as invalid on Solaris. |
CL https://golang.org/cl/29892 mentions this issue. |
CL https://golang.org/cl/29891 mentions this issue. |
CL https://golang.org/cl/29893 mentions this issue. |
This change introduces a package that provides basic functions for the manipulation of logical network interfaces, interface addresses and data links on Solaris. As BSD variants implement routing socket and routing messages, Linux implements netlink socket and netlink messages, Solaris implements STREAMS-like interface for reading, writing network facility information inside the kernel. The package wraps various I/O control calls which involve message exchanges between kernel protocol modules in exposed APIs. At present, the package supports Solaris 11 or above. Updates golang/go#7177. Change-Id: I192d85e53b0bee942dfefca0f73a3eb94ab8bfe9 Reviewed-on: https://go-review.googlesource.com/29893 Reviewed-by: Ian Lance Taylor <iant@golang.org>
golang.org/x/net/lif becomes vendor/golang_org/x/net/lif. At git rev 9f0e377 (golang.org/cl/29893) Updates #7177. Change-Id: Id838fcc234e71f735bb2609073f4c2214b48a970 Reviewed-on: https://go-review.googlesource.com/29891 Reviewed-by: Ian Lance Taylor <iant@golang.org>
The text was updated successfully, but these errors were encountered: