Skip to content

Unable to create index.lock

Summary

When i stop job at at the beginning of it work, gitlab leaves index.lock file.

Steps to reproduce

  1. Start job. See black cmd screen with loading indicator (three horizontal dots).
  2. Cancel job immediately.
  3. Repeat steps 1-2 on same machine two-three times.

Example Project

What is the current bug behavior?

The machine what has index.lock file does not work properly. Runner starts and aborts fast. This machine takes next job, and fail again. So, one bad machine cause fails almost all jobs.

What is the expected correct behavior?

Index.lock must be removed at job start.

Relevant logs and/or screenshots

Screenshot

https://www.screencast.com/t/RfiGCqFNN9

Output of checks

Results of GitLab environment info

Results of GitLab application Check

Possible fixes

I use the "pre_clone_script" option. Its starts python script that find and remove index.lock