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

syscall: test failed on TestAmbientCapsUserns on master branch 5930c7d #30698

Closed
shuLhan opened this issue Mar 9, 2019 · 8 comments
Closed
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done. Testing An issue that has been verified to require only test changes, not just a test failure.
Milestone

Comments

@shuLhan
Copy link
Contributor

shuLhan commented Mar 9, 2019

What version of Go are you using (go version)?

$ go version
go version devel +5930c7de93 Fri Mar 8 20:53:16 2019 +0000 linux/amd64

Does this issue reproduce with the latest release?

No.

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GOARCH="amd64"
GOBIN="/home/ms/bin"
GOCACHE="/home/ms/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/ms/go"
GOPROXY=""
GORACE="history_size=7"
GOROOT="/home/ms/Programs/go"
GOTMPDIR=""
GOTOOLDIR="/home/ms/Programs/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build730915919=/tmp/go-build -gno-record-gcc-switches"

System,

regression ms 0 % uname -a
Linux kilabit.local 5.0.0-arch1-1-ARCH #1 SMP PREEMPT Mon Mar 4 14:11:43 UTC 2019 x86_64 GNU/Linux

all-gofmt ms 0 % gcc --version
gcc (GCC) 8.2.1 20181127

all-gofmt ms 0 % pacman -Qi glibc
Name            : glibc
Version         : 2.28-5

sysctl: https://gist.github.com/shuLhan/8e89236998ebb017d9fe3700eed6710a

What did you do?

Rebuild Go from the source code from commit 5930c7d.

What did you expect to see?

Build success.

What did you see instead?

ok      sync    0.551s
ok      sync/atomic     0.037s
--- FAIL: TestAmbientCapsUserns (0.00s)
    exec_linux_test.go:616: fork/exec /tmp/gotest178771049: operation not permitted
FAIL
FAIL    syscall 0.074s
ok      testing 1.299s
...
ok      cmd/vendor/golang.org/x/sys/unix        0.562s
ok      cmd/vet 4.843s
2019/03/09 05:59:20 Failed: exit status 1
@bradfitz bradfitz changed the title build: test failed on TestAmbientCapsUserns on master branch 5930c7d syscall: test failed on TestAmbientCapsUserns on master branch 5930c7d Mar 9, 2019
@bradfitz bradfitz added this to the Go1.13 milestone Mar 9, 2019
@bradfitz bradfitz added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Mar 9, 2019
@bradfitz
Copy link
Contributor

bradfitz commented Mar 9, 2019

What's your distro, kernel, and versions thereof? Any other special system tweaks or notable config?

@shuLhan
Copy link
Contributor Author

shuLhan commented Mar 9, 2019

I have update description.

regression ms 0 % uname -a
Linux kilabit.local 5.0.0-arch1-1-ARCH #1 SMP PREEMPT Mon Mar 4 14:11:43 UTC 2019 x86_64 GNU/Linux

all-gofmt ms 0 % gcc --version
gcc (GCC) 8.2.1 20181127

all-gofmt ms 0 % pacman -Qi glibc
Name            : glibc
Version         : 2.28-5

sysctl: https://gist.github.com/shuLhan/8e89236998ebb017d9fe3700eed6710a

Any other special system tweaks or notable config?

I believe I don't do any tweaks.

@bradfitz
Copy link
Contributor

bradfitz commented Mar 9, 2019

We don't yet have an Arch builder (at https://build.golang.org). That is #9505 and might prevent these sort of breakages in the future.

@ALTree
Copy link
Member

ALTree commented Mar 9, 2019

This is not Arch-related, I've just hit this on Debian running all.bash.

$ uname -a
Linux gauss 4.19.0-2-amd64 #1 SMP Debian 4.19.16-1 (2019-01-17) x86_64 GNU/Linux

@ALTree ALTree added the Testing An issue that has been verified to require only test changes, not just a test failure. label Mar 9, 2019
@ALTree
Copy link
Member

ALTree commented Mar 9, 2019

The offending setting is likely kernel.unprivileged_userns_clone = 0, an old friend. It prevents unprivileged user from creating namespaces.

@shuLhan Can you check if CL 166460 (which contains a Skip check that I lifted from another syscall test) fixes the issue on your system? It does on mine. Thanks.

@shuLhan
Copy link
Contributor Author

shuLhan commented Mar 10, 2019

@ALTree OK, wait a moment.

@shuLhan
Copy link
Contributor Author

shuLhan commented Mar 10, 2019

@ALTree CL 166460 fix the build process on my system.

Build log: https://gist.github.com/shuLhan/210bbb28368ea00d34840f8d541582cf

@ALTree ALTree added NeedsFix The path to resolution is known, but the work has not been done. and removed NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Mar 10, 2019
@gopherbot
Copy link

Change https://golang.org/cl/166460 mentions this issue: syscall: skip non-root user namespace test if kernel forbids

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done. Testing An issue that has been verified to require only test changes, not just a test failure.
Projects
None yet
Development

No branches or pull requests

4 participants