-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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: test is failing on Dragonfly builder #34368
Comments
According to Matt Dillon, the structural elements in the route messages have changed. DF team is working on a fix. |
It seems we need to adjust a defs file in https://github.com/golang/net but we're not sure what's the workflow to get those changes into Go. Can you please let us know? |
The process for the |
@tdfbsd the dragonfly builder is a line of red on build.golang.org with a number of failures still: https://build.golang.org/log/e33c85c1a7f2e094141d05bafa426c9038a2bce3 Any update on progress? |
I think @tuxillo is still working this. |
|
@tuxillo checkout out the dragonfly column on https://build.golang.org/ to see what @andybons is referring to. |
Ah, I see, still the route mistmatch thing. There was a commit to x/net, see: golang/net@c5a3c61 I don't know how x/net is imported into Golang, how can I help? |
@tuxillo, see https://github.com/golang/go/blob/master/src/README.vendor But I don't see how golang/net@c5a3c61 could help --- that just removes some symbols, no? |
@bradfitz as far as I understand it, this file is autogenerated based on the defs file: So when that file is generated again, it will have the correct RTM_VERSION and the "message mismatch" should go away. |
@tuxillo you have to generate the file (on a Dragonfly machine) then send that change for review. The instructions are at the top of the generated file. As a tip, |
@andybons oh I thought there was some merging from 'x/net' to golang somehow and frequently. I'll do that then. |
Change https://golang.org/cl/199557 mentions this issue: |
I installed DragonFly 5.6.2 and ran the tests as root at tip and they all passed. Including golang.org/x/net/route. What version are you running, @tdfbsd? |
Nevermind. I see this a problem at Dragonfly master. |
@bradfitz it affects only master because we've bumped RTM_VERSION there and not in RELEASE (5.6.2) but in the next release it will also fail. With regards to: "In any case, even if we re-generate the zsys_dragonfly.go files in x/net/route and x/net/ipv6, it only removes 3 lines of unexported constants that nothing ever uses, so that won't help fix the broken builders." That's only partially true. It would also get the new RTM_VERSION. I've regenerated it locally and it did:
In any case, I have two things that I'd like to know:
|
Absolutely! See http://golang.org/wiki/DashboardBuilders for instructions on how to add a new builder.
That seems like more of a Dragonfly question — does the Dragonfly kernel not provide a stable syscall ABI? (If it does not, perhaps we should change Dragonfly to use a C syscall library, as we did for macOS in #17490; CC @randall77.) |
It's presenting a new RTM_VERSION in the headers so it's stable, right?. The way I see, the problem is that a statically generated file in x/net won't match the OS headers and hence cause problems. |
What effect does changing Do Dragonfly kernels provide ABI compatibility with previous |
Sorry, I mean the API is the same but indeed the ABI is not backwards compatible after the bump of RTM_VERSION. We don't have a compat layer, unfortunately. |
That's unfortunate. Is that the official Dragonfly policy or was that just an accidental ABI/compat breakage? Should Go be detecting the kernel version at runtime and using a different ABI depending on where we find ourselves? Or should Go only target the latest release? Or should Go only target master? For instance, for other operating systems we have policies & docs on this, like: https://github.com/golang/go/wiki/OpenBSD
We need to figure out what the Dragonfly policy is. |
It's not acciental breakage and it's no different from OpenBSD. How Go wants to support it is up to Go. My recommendation would be to figure it out at compile time like every other program that depends on RTM_VERSION. http://lists.dragonflybsd.org/pipermail/users/2019-September/358280.html |
To be clear, the Go team doesn't maintain the Dragonfly port.
No other Go port does, that, IIRC. We either probe the kernel at runtime and figure out what ABI we need to speak (e.g. https://github.com/golang/net/blob/146acd2/route/sys_freebsd.go#L59) or we call C functions instead (Solaris, Darwin, Windows?), but it sounds like that's not even stable here. Dragonfly-Go maintainers need to decide: do you support stable? Or only tip? Or both tip+stable? If the latter, I suggest one of the Dragonfly-Go maintainers starts writing some code to probe which kernel/ABI version is applicable or add some conditional paths to do the right thing depending on the environment. |
Thanks @bradfitz, we'll discuss it and we'll update this issue when we come to a conclusion. Please don't close it. |
Change https://golang.org/cl/201482 mentions this issue: |
@bradfitz initially we're going to try to support both directly in Go. The alternative would be supporting tip (master branch) and do some patching in our package system but I think that doesn't scale for future changes, so we're leaving it as last resort for now. I've been taking a look at |
@tuxillo, is The only use of it I see is in Can |
In About returning an error unconditionally, I'm not sure. We'd have to test. |
The |
Change https://golang.org/cl/201740 mentions this issue: |
Skipping tests isn't great, but neither is a wall of red masking other potential regressions. Updates #34368 Change-Id: I5fdfa54846dd8d648001594c74f059af8af52247 Reviewed-on: https://go-review.googlesource.com/c/go/+/201482 Run-TryBot: Brad Fitzpatrick <[email protected]> Reviewed-by: Bryan C. Mills <[email protected]>
Updates #15581 Updates #34368 Change-Id: Ife3be7ed484cbe87960bf972ac701954d86127d8 Reviewed-on: https://go-review.googlesource.com/c/go/+/201740 Reviewed-by: Bryan C. Mills <[email protected]>
As a reference, the error that appeared on the tests is errMessageMismatch which comes from ParseRIB in The call stack is something like this: (Multiple places) I wonder if I can hardcode something like sysRTM_VERSION56 in the defs file (which is then parsed by cgo) and put a conditional check in ParseRIB, maybe that would work? |
Change https://golang.org/cl/202317 mentions this issue: |
Detect the ABI version based on kern.osreldate. Only use 32-bit cmsg alignment for versions before the September 2019 ABI changes: http://lists.dragonflybsd.org/pipermail/users/2019-September/358280.html Use RTM_VERSION 7 on Dragonfly master (5.8 release). Determine sizeof struct ifa_msghdr at runtime based on the ABI version. Temporarily skip some test relying on the net package which will only be fixed once this CL is re-vendored into std. Updates golang/go#34368 Change-Id: I732fab21d569b303f45dfb6a0bbbb11469511a07 Reviewed-on: https://go-review.googlesource.com/c/net/+/202317 Run-TryBot: Tobias Klauser <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]>
Change https://golang.org/cl/202438 mentions this issue: |
Change https://golang.org/cl/202457 mentions this issue: |
Now that golang.org/x/net was re-vendored into std, these tests should pass again. Updates golang/go#34368 Change-Id: I6f253896836fb18d46875a9420de58ca05a49646 Reviewed-on: https://go-review.googlesource.com/c/net/+/202457 Run-TryBot: Tobias Klauser <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Brad Fitzpatrick <[email protected]>
Change https://golang.org/cl/217358 mentions this issue: |
Both the Dragonfly release and tip builder have been passing for a while. The net package's interface API is working on both builders since CL 202317 which has been re-vendored in CL 202438. Updates #34368 Updates #36878 Change-Id: I187178b3a59f2604187af453207fb4e24a56105c Reviewed-on: https://go-review.googlesource.com/c/go/+/217358 Reviewed-by: Ian Lance Taylor <[email protected]>
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?DragonflyBSD amd64
What did you do?
The net test is consistently failing after I upgraded the OS to a recent commit:
https://build.golang.org/log/58be31cfd1a92ba9582fdf33e01f79e03184e59b
At first glance, this appears to be a Dragonfly bug
http://bugs.dragonflybsd.org/issues/3205
The text was updated successfully, but these errors were encountered: