Gitlab fails to accept Gitlab runner traces, jobs get stuck and timeout
Summary
Gitlab does not process CI/CD job traces and does not reply to runners, thus jobs get stuck and end up in timeout.
Steps to reproduce
- Trigger a new pipeline in our self-hosted Gitlab instance.
- The jobs get picked up by self-hosted runners.
- The job trace shows only the first lines of the log, then it gets stuck.
What is the current bug behavior?
Jobs traces don't show as complete, even though the Gitlab runner shows jobs as succeeded.
What is the expected correct behavior?
Job traces should be accepted by Gitlab.
Relevant logs and/or screenshots
Gitlab runner output:
Mar 23 13:51:39 gitlab-runner[1463266]: Job succeeded duration_s=89.758777136 job=105118 project=416 runner=KAzMiQhy
Mar 23 13:51:58 gitlab-runner[1463266]: ERROR: Appending trace to coordinator... error couldn't execute PATCH against https://[redacted]/api/v4/jobs/105117/trace?debug_trace=false: Patch "https://[redacted]/api/v4/jobs/105117/trace?debug_trace=false": EOF runner=KAzMiQhy
Mar 23 13:52:02 gitlab-runner[1463266]: ERROR: Appending trace to coordinator... error couldn't execute PATCH against https://[redacted]/api/v4/jobs/105116/trace?debug_trace=false: Patch "https://[redacted]/api/v4/jobs/105116/trace?debug_trace=false": EOF runner=KAzMiQhy
It happens with different runners in different environments, versions 14.8 and 15.10.0 were tested (we upgraded everything to ensure it wasn't related to the runner version).
Job trace output:
There are no relevant logs in the Gitlab logs. The Nginx proxy doesn't show the request as either processed or failed until it times out. There are no traces of the missing PATCH calls in the logs either.
We have only found this message: Cannot obtain an exclusive lease for ci/pipeline_processing/atomic_processing_service::pipeline_id:26778. There must be another instance already in execution.. However, according to #331033 (closed), it should be ignored. We nevertheless tried the steps listed in that issue to remove the exclusive leases to see if it would fix our issue, without success.
Output of checks
Results of GitLab environment info
This has started happening today, we did not do any changes to the environment.
The issue happens with different runners on different networks. We have checked and there are no issues with firewalls, the requests are getting to Gitlab, but it's not responding.
Expand for output related to GitLab environment info
System information System: Current User: git Using RVM: no Ruby Version: 2.7.7p221 Gem Version: 3.1.6 Bundler Version:2.3.15 Rake Version: 13.0.6 Redis Version: 6.2.8 Sidekiq Version:6.5.7 Go Version: unknown GitLab information Version: 15.9.3 Revision: f030ca96950 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 12.12 URL: https://[redacted] HTTP Clone URL: https://[redacted]/some-group/some-project.git SSH Clone URL: git@[redacted]:some-group/some-project.git Using LDAP: no Using Omniauth: yes Omniauth Providers: GitLab Shell Version: 14.17.0 Repository storages: - default: unix:/var/opt/gitlab/gitaly/gitaly.socket GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell
Results of GitLab application Check
Expand for output related to the GitLab application check
Checking GitLab subtasks ...Checking GitLab Shell ...
GitLab Shell: ... GitLab Shell version >= 14.17.0 ? ... OK (14.17.0) Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Internal API available: OK Redis available via internal API: OK gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Gitaly ...
Gitaly: ... default ... OK
Checking Gitaly ... Finished
Checking Sidekiq ...
Sidekiq: ... Running? ... yes Number of Sidekiq processes (cluster/worker) ... 1/1
Checking Sidekiq ... Finished
Checking Reply by email ... Finished
Checking Incoming Email ... Finished
Checking LDAP ...
LDAP: ... LDAP is disabled in config/gitlab.yml
Checking LDAP ... Finished
Checking GitLab App ...
Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Cable config exists? ... yes Resque config exists? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Systemd unit files or init script exist? ... skipped (omnibus-gitlab has neither init script nor systemd units) Systemd unit files or init script up-to-date? ... skipped (omnibus-gitlab has neither init script nor systemd units) Projects have namespace: ... 27/19 ... yes 84/22 ... yes 8/37 ... yes 8/38 ... yes 27/39 ... yes 8/46 ... yes 17/53 ... yes 17/55 ... yes 6/70 ... yes 27/83 ... yes 27/91 ... yes 27/94 ... yes 53/95 ... yes 53/116 ... yes 6/119 ... yes 77/122 ... yes 8/143 ... yes 84/144 ... yes 54/158 ... yes 27/166 ... yes 52/171 ... yes 53/172 ... yes 53/173 ... yes 54/179 ... yes 53/184 ... yes 27/186 ... yes 54/188 ... yes 27/189 ... yes 27/194 ... yes 53/195 ... yes 53/197 ... yes 53/201 ... yes 53/202 ... yes 60/210 ... yes 53/211 ... yes 60/212 ... yes 60/213 ... yes 60/214 ... yes 54/215 ... yes 27/216 ... yes 53/217 ... yes 75/218 ... yes 52/222 ... yes 75/223 ... yes 54/224 ... yes 75/225 ... yes 27/228 ... yes 27/230 ... yes 54/231 ... yes 52/232 ... yes 53/233 ... yes 27/236 ... yes 75/237 ... yes 54/238 ... yes 53/241 ... yes 65/242 ... yes 65/243 ... yes 65/244 ... yes 65/245 ... yes 65/246 ... yes 65/247 ... yes 65/248 ... yes 53/249 ... yes 72/250 ... yes 72/251 ... yes 72/252 ... yes 460/253 ... yes 72/255 ... yes 72/257 ... yes 75/258 ... yes 27/259 ... yes 53/260 ... yes 53/261 ... yes 72/264 ... yes 77/266 ... yes 72/267 ... yes 27/269 ... yes 72/270 ... yes 72/272 ... yes 72/273 ... yes 3/274 ... yes 27/278 ... yes 27/282 ... yes 53/284 ... yes 72/287 ... yes 69/288 ... yes 27/289 ... yes 27/290 ... yes 27/291 ... yes 27/292 ... yes 73/293 ... yes 2/295 ... yes 75/296 ... yes 2/297 ... yes 53/298 ... yes 82/302 ... yes 52/303 ... yes 27/304 ... yes 27/305 ... yes 29/306 ... yes 72/307 ... yes 60/308 ... yes 60/309 ... yes 27/310 ... yes 27/311 ... yes 87/312 ... yes 3/313 ... yes 6/315 ... yes 6/316 ... yes 60/317 ... yes 60/318 ... yes 66/319 ... yes 38/320 ... yes 92/321 ... yes 27/322 ... yes 60/323 ... yes 60/324 ... yes 75/325 ... yes 88/326 ... yes 60/327 ... yes 91/328 ... yes 84/329 ... yes 72/330 ... yes 38/332 ... yes 2/333 ... yes 88/334 ... yes 88/335 ... yes 14/336 ... yes 60/337 ... yes 52/338 ... yes 27/339 ... yes 60/340 ... yes 27/341 ... yes 27/342 ... yes 90/343 ... yes 90/344 ... yes 60/345 ... yes 27/346 ... yes 27/347 ... yes 90/348 ... yes 60/349 ... yes 91/350 ... yes 91/351 ... yes 82/352 ... yes 92/353 ... yes 90/354 ... yes 91/355 ... yes 60/356 ... yes 87/357 ... yes 27/359 ... yes 92/360 ... yes 38/361 ... yes 91/363 ... yes 91/364 ... yes 27/365 ... yes 75/366 ... yes 75/367 ... yes 38/368 ... yes 92/369 ... yes 92/370 ... yes 70/371 ... yes 60/372 ... yes 27/373 ... yes 87/374 ... yes 92/375 ... yes 88/376 ... yes 90/377 ... yes 27/378 ... yes 93/379 ... yes 94/380 ... yes 38/381 ... yes 29/382 ... yes 91/383 ... yes 27/384 ... yes 91/385 ... yes 94/389 ... yes 75/390 ... yes 84/391 ... yes 84/392 ... yes 84/393 ... yes 72/394 ... yes 38/395 ... yes 88/396 ... yes 27/397 ... yes 85/398 ... yes 71/399 ... yes 38/400 ... yes 38/401 ... yes 20/402 ... yes 72/403 ... yes 91/404 ... yes 94/405 ... yes 60/406 ... yes 85/407 ... yes 93/408 ... yes 91/409 ... yes 91/410 ... yes 94/411 ... yes 27/412 ... yes 27/413 ... yes 27/414 ... yes 94/415 ... yes 84/416 ... yes 92/417 ... yes 72/418 ... yes 92/419 ... yes 101/420 ... yes 101/421 ... yes 101/422 ... yes 38/423 ... yes 70/424 ... yes 94/425 ... yes 62/426 ... yes 31/427 ... yes 75/428 ... yes 38/429 ... yes 101/430 ... yes 103/431 ... yes 94/432 ... yes 38/433 ... yes 27/434 ... yes 92/436 ... yes 91/437 ... yes 103/438 ... yes 75/439 ... yes 70/440 ... yes 27/441 ... yes 27/442 ... yes 27/443 ... yes 103/444 ... yes 27/445 ... yes 27/446 ... yes 86/447 ... yes 71/448 ... yes 72/449 ... yes 91/450 ... yes 106/451 ... yes 107/452 ... yes 94/453 ... yes 90/454 ... yes 87/455 ... yes 87/457 ... yes 87/458 ... yes 110/459 ... yes 107/461 ... yes 90/462 ... yes 100/463 ... yes 101/464 ... yes 101/465 ... yes 112/466 ... yes 103/467 ... yes 87/468 ... yes 97/469 ... yes 91/470 ... yes 91/471 ... yes 27/472 ... yes 112/473 ... yes 110/474 ... yes 112/475 ... yes 92/476 ... yes 70/477 ... yes 27/479 ... yes 101/480 ... yes 87/483 ... yes 87/485 ... yes 87/486 ... yes 87/487 ... yes 92/490 ... yes 38/491 ... yes 87/492 ... yes 107/493 ... yes 71/494 ... yes 27/495 ... yes 91/496 ... yes 115/497 ... yes 27/498 ... yes 101/499 ... yes 27/501 ... yes 68/502 ... yes 90/503 ... yes 91/504 ... yes 27/505 ... yes 118/506 ... yes 118/507 ... yes 2/508 ... yes 2/509 ... yes 2/510 ... yes 101/511 ... yes 72/512 ... yes 105/513 ... yes 27/515 ... yes 105/516 ... yes 119/517 ... yes 117/518 ... yes 87/519 ... yes 3/520 ... yes 27/522 ... yes 27/523 ... yes 60/524 ... yes 94/525 ... yes 114/526 ... yes 424/527 ... yes 68/528 ... yes 101/529 ... yes 91/530 ... yes 424/531 ... yes 84/532 ... yes 94/533 ... yes 27/534 ... yes 435/535 ... yes 435/536 ... yes 435/537 ... yes 435/538 ... yes 84/539 ... yes 112/541 ... yes 115/542 ... yes 91/543 ... yes 94/544 ... yes 447/545 ... yes 447/546 ... yes 27/547 ... yes 3/548 ... yes 66/549 ... yes 104/550 ... yes 108/551 ... yes 451/552 ... yes 435/553 ... yes 435/554 ... yes 461/555 ... yes 66/556 ... yes 460/557 ... yes 67/558 ... yes 447/559 ... yes 435/560 ... yes 104/561 ... yes 435/562 ... yes 109/563 ... yes 116/564 ... yes 435/567 ... yes 105/569 ... yes Redis version >= 6.0.0? ... yes Ruby version >= 2.7.2 ? ... yes (2.7.7) Git user has default SSH configuration? ... yes Active users: ... 37 Is authorized keys file accessible? ... yes GitLab configured to store new projects in hashed storage? ... yes All projects are in hashed storage? ... yes
Checking GitLab App ... Finished
Checking GitLab subtasks ... Finished
