earthly: panic: failed to get edge
I’ve recently upgraded to Earthly 0.5.13 and our CI jobs that run multiple Earthly targets in parallel have started failing with errors such as this:
# ...other yarn install logs...
./p/sometarget+dependencies | [5/5] Building fresh packages...
./p/sometarget+dependencies | success Saved lockfile.
./p/sometarget+dependencies | Done in 102.14s.
./p/sometarget+dependencies | yarn cache v1.22.0
./p/sometarget+dependencies | success Cleared cache.
./p/sometarget+dependencies | Done in 6.45s.
=================================Buildkit Logs==================================
Error: transport is closing
It seems that buildkitd is shutting down or it has crashed. You can report crashes at https://github.com/earthly/earthly/issues/new.
starting earthly-buildkit with EARTHLY_GIT_HASH=a7f082f8fade1badbee0a221c9a9da2317449e4c BUILDKIT_BASE_IMAGE=github.com/earthly/buildkit:c1749dff2545b0202fc15f33eaa3278b1aa8803e+build
BUILDKIT_ROOT_DIR=/tmp/earthly/buildkit
CACHE_SIZE_MB=150000
EARTHLY_ADDITIONAL_BUILDKIT_CONFIG=
CNI_MTU=1500
======== CNI config ==========
{
"cniVersion": "0.3.0",
"name": "buildkitbuild",
"type": "bridge",
"bridge": "cni0",
"isGateway": true,
"ipMasq": true,
"mtu": 1500,
"ipam": {
"type": "host-local",
"subnet": "172.30.0.0/16",
"routes": [
{ "dst": "0.0.0.0/0" }
]
}
}
======== End CNI config ==========
======== Buildkitd config ==========
debug = false
root = "/tmp/earthly/buildkit"
insecure-entitlements = [ "security.insecure" ]
[worker.oci]
enabled = true
snapshotter = "auto"
gc = true
networkMode = "cni"
cniBinaryPath = "/usr/libexec/cni"
cniConfigPath = "/etc/cni/cni-conf.json"
# Please note the required indentation to fit in buildkit.toml.template accordingly.
# 1/100 of total cache size.
gckeepstorage = 1500000000
[[worker.oci.gcpolicy]]
# 1/10 of total cache size.
keepBytes = 15000000000
filters = [ "type==source.local", "type==source.git.checkout"]
[[worker.oci.gcpolicy]]
all = true
# Cache size MB with 6 zeros, to turn it into bytes.
keepBytes = 150000000000
======== End buildkitd config ==========
Detected container architecture is x86_64
starting shellrepeater
time="2021-05-27T14:06:14Z" level=info msg="auto snapshotter: using overlayfs"
time="2021-05-27T14:06:29Z" level=info msg="found worker \"7dl0od0h2nmn3awn6fgkr04er\", labels=map[org.mobyproject.buildkit.worker.executor:oci org.mobyproject.buildkit.worker.hostname:9a81ae26219d org.mobyproject.buildkit.worker.snapshotter:overlayfs], platforms=[linux/amd64 linux/386]"
time="2021-05-27T14:06:29Z" level=warning msg="skipping containerd worker, as \"/run/containerd/containerd.sock\" does not exist"
time="2021-05-27T14:06:29Z" level=info msg="found 1 workers, default=\"7dl0od0h2nmn3awn6fgkr04er\""
time="2021-05-27T14:06:29Z" level=warning msg="currently, only the default worker can be used."
time="2021-05-27T14:06:29Z" level=info msg="running server on /run/buildkit/buildkitd.sock"
panic: failed to get edge
goroutine 16 [running]:
github.com/moby/buildkit/solver.(*pipeFactory).NewInputRequest(0xc00c90def8, 0x0, 0x1549b20, 0xc00c6d8700, 0xc01bed6400, 0xc001961928, 0xc00453d200)
/src/solver/scheduler.go:354 +0x1fc
github.com/moby/buildkit/solver.(*edge).createInputRequests(0xc001960dc0, 0x2, 0xc00c90def8, 0x0, 0x1dff070)
/src/solver/edge.go:809 +0x31d
github.com/moby/buildkit/solver.(*edge).unpark(0xc001960dc0, 0xc01bed8420, 0x1, 0x1, 0xc00c90de48, 0x0, 0x0, 0x1dff070, 0x0, 0x0, ...)
/src/solver/edge.go:360 +0x179
github.com/moby/buildkit/solver.(*scheduler).dispatch(0xc00023d180, 0xc001960dc0)
/src/solver/scheduler.go:136 +0x430
github.com/moby/buildkit/solver.(*scheduler).loop(0xc00023d180)
/src/solver/scheduler.go:104 +0x179
created by github.com/moby/buildkit/solver.newScheduler
/src/solver/scheduler.go:35 +0x1ab
Similar logs in the job that is in progress at the same time…
./p/someothertarget+dependencies | [5/5] Building fresh packages...
./p/someothertarget+dependencies | success Saved lockfile.
./p/someothertarget+dependencies | Done in 85.08s.
./p/someothertarget+dependencies | yarn cache v1.22.0
./p/someothertarget+dependencies | success Cleared cache.
./p/someothertarget+dependencies | Done in 7.32s.
./p/someothertarget+dependencies | package=someothertarget
./p/someothertarget+dependencies | *cached* --> SAVE ARTIFACT ./ ./packages/someothertarget+dependencies/app
=================================Buildkit Logs==================================
Error: transport is closing
It seems that buildkitd is shutting down or it has crashed. You can report crashes at https://github.com/earthly/earthly/issues/new.
starting earthly-buildkit with EARTHLY_GIT_HASH=a7f082f8fade1badbee0a221c9a9da2317449e4c BUILDKIT_BASE_IMAGE=github.com/earthly/buildkit:c1749dff2545b0202fc15f33eaa3278b1aa8803e+build
BUILDKIT_ROOT_DIR=/tmp/earthly/buildkit
CACHE_SIZE_MB=150000
EARTHLY_ADDITIONAL_BUILDKIT_CONFIG=
CNI_MTU=1500
======== CNI config ==========
{
"cniVersion": "0.3.0",
"name": "buildkitbuild",
"type": "bridge",
"bridge": "cni0",
"isGateway": true,
"ipMasq": true,
"mtu": 1500,
"ipam": {
"type": "host-local",
"subnet": "172.30.0.0/16",
"routes": [
{ "dst": "0.0.0.0/0" }
]
}
}
======== End CNI config ==========
======== Buildkitd config ==========
debug = false
root = "/tmp/earthly/buildkit"
insecure-entitlements = [ "security.insecure" ]
[worker.oci]
enabled = true
snapshotter = "auto"
gc = true
networkMode = "cni"
cniBinaryPath = "/usr/libexec/cni"
cniConfigPath = "/etc/cni/cni-conf.json"
# Please note the required indentation to fit in buildkit.toml.template accordingly.
# 1/100 of total cache size.
gckeepstorage = 1500000000
[[worker.oci.gcpolicy]]
# 1/10 of total cache size.
keepBytes = 15000000000
filters = [ "type==source.local", "type==source.git.checkout"]
[[worker.oci.gcpolicy]]
all = true
# Cache size MB with 6 zeros, to turn it into bytes.
keepBytes = 150000000000
======== End buildkitd config ==========
Detected container architecture is x86_64
starting shellrepeater
time="2021-05-27T14:06:14Z" level=info msg="auto snapshotter: using overlayfs"
time="2021-05-27T14:06:29Z" level=info msg="found worker \"7dl0od0h2nmn3awn6fgkr04er\", labels=map[org.mobyproject.buildkit.worker.executor:oci org.mobyproject.buildkit.worker.hostname:9a81ae26219d org.mobyproject.buildkit.worker.snapshotter:overlayfs], platforms=[linux/amd64 linux/386]"
time="2021-05-27T14:06:29Z" level=warning msg="skipping containerd worker, as \"/run/containerd/containerd.sock\" does not exist"
time="2021-05-27T14:06:29Z" level=info msg="found 1 workers, default=\"7dl0od0h2nmn3awn6fgkr04er\""
time="2021-05-27T14:06:29Z" level=warning msg="currently, only the default worker can be used."
time="2021-05-27T14:06:29Z" level=info msg="running server on /run/buildkit/buildkitd.sock"
panic: failed to get edge
goroutine 16 [running]:
github.com/moby/buildkit/solver.(*pipeFactory).NewInputRequest(0xc00c90def8, 0x0, 0x1549b20, 0xc00c6d8700, 0xc01bed6400, 0xc001961928, 0xc00453d200)
/src/solver/scheduler.go:354 +0x1fc
github.com/moby/buildkit/solver.(*edge).createInputRequests(0xc001960dc0, 0x2, 0xc00c90def8, 0x0, 0x1dff070)
/src/solver/edge.go:809 +0x31d
github.com/moby/buildkit/solver.(*edge).unpark(0xc001960dc0, 0xc01bed8420, 0x1, 0x1, 0xc00c90de48, 0x0, 0x0, 0x1dff070, 0x0, 0x0, ...)
/src/solver/edge.go:360 +0x179
github.com/moby/buildkit/solver.(*scheduler).dispatch(0xc00023d180, 0xc001960dc0)
/src/solver/scheduler.go:136 +0x430
github.com/moby/buildkit/solver.(*scheduler).loop(0xc00023d180)
/src/solver/scheduler.go:104 +0x179
created by github.com/moby/buildkit/solver.newScheduler
/src/solver/scheduler.go:35 +0x1ab
Should running jobs in parallel on the same machine be OK? They are both run in Gitlab via Docker executors but on the same Docker host so the buildkitd instance is shared.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 15 (6 by maintainers)
This doesn’t appear to be happening after the recent buildkit merges, thanks!