ERROR when I rebuild prysm using bazel
daniel5713 opened this issue Β· comments
π Issue
Input:
bazel build //cmd/beacon-chain:beacon-chain --config=release
Output:
ERROR: ethereum/consensus/prysm/cmd/beacon-chain/BUILD.bazel:47:10: GoLink cmd/beacon-chain/beacon-chain_/beacon-chain failed: (Exit 1): builder failed: error executing GoLink command (from target //cmd/beacon-chain:beacon-chain) bazel-out/k8-opt-exec-ST-13d3ddad9198/bin/external/go_sdk/builder_reset/builder '-param=bazel-out/k8-opt/bin/cmd/beacon-chain/beacon-chain_/beacon-chain-0.params' -- -extld ... (remaining 4 arguments skipped)
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/go_sdk/pkg/tool/linux_amd64/link: running external/zig_sdk/tools/x86_64-linux-gnu.2.31/c++ failed: exit status 1
error: unable to create compilation: AccessDenied
link: error running subcommand GOOS=linux
GOPATH=
GOROOT_FINAL=GOROOT
GOROOT=bazel-out/k8-opt-ST-30607a78c395/bin/external/io_bazel_rules_go/stdlib_
GOEXPERIMENT=nocoverageredesign
GOTOOLCHAIN=local
TMPDIR=/tmp
PATH=external/zig_sdk/tools:external/zig_sdk/tools/x86_64-linux-gnu.2.31:/bin:/usr/bin
GOARCH=amd64
CGO_ENABLED=1
external/go_sdk/pkg/tool/linux_amd64/link -importcfg /root/.cache/bazel/_bazel_root/ae497eedb93063696cb316fe77801cf1/sandbox/linux-sandbox/3/execroot/main/bazel-out/k8-opt/bin/cmd/beacon-chain/beacon-chain/importcfg59797049 -X github.com/prysmaticlabs/prysm/v5/runtime/version.gitCommit=ea2624b5abc49ef8d05c9ea0ba027eaccdf07850 -X "github.com/prysmaticlabs/prysm/v5/runtime/version.buildDate=2024-06-05 09:00:10+00:00" -X github.com/prysmaticlabs/prysm/v5/runtime/version.buildDateUnix=1717578010 -X github.com/prysmaticlabs/prysm/v5/runtime/version.gitTag=v5.0.3 -o /root/.cache/bazel/_bazel_root/ae497eedb93063696cb316fe77801cf1/sandbox/linux-sandbox/3/execroot/main/bazel-out/k8-opt/bin/cmd/beacon-chain/beacon-chain/beacon-chain -extld external/zig_sdk/tools/x86_64-linux-gnu.2.31/c++ -buildid=redacted -extldflags "-O2 -DNDEBUG" /root/.cache/bazel/_bazel_root/ae497eedb93063696cb316fe77801cf1/sandbox/linux-sandbox/3/execroot/_main/bazel-out/k8-opt/bin/cmd/beacon-chain/beacon-chain.a: exit status 2
INFO: Found 1 target...
Target //cmd/beacon-chain:beacon-chain failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 2.009s, Critical Path: 1.83s
INFO: 2 processes: 2 internal.
ERROR: Build did NOT complete successfully
What should I do to fix it?
Thanks in advance!
it says in the error
unable to create compilation: AccessDenied
I think you just didn't give access to wherever you are building this I think
Looks like a file system permissions issue.
Root login. It works.