Reputation: 835
We are using GitLab 11.2.1-ee with git-lfs (v.2.4.2) enabled.
We found that we have corrupted object in git-lfs on server. When we run
sudo gitlab-rake gitlab:lfs:check VERBOSE=1
, we have
- 1401..1600: Failures: 1
- LFS object: b675b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491: Checksum mismatch
Now when we try to do
git lfs pull
in clones, we got
Expected OID b675b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491, got 2c6abc2c4d29bd1c7f0041160ea15ea2765df10194a6e9ef3e6e2139c11fc67f after 12427595 bytes written
error: failed to fetch some objects from 'https://192.168.1.100/root/our_project.git/info/lfs'
How should we fix this corruption?
Upvotes: 2
Views: 1047
Reputation: 835
Solved.
We found that sha256sum of contents of file b6/75/b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491
on server equals to 2c6abc2c4d29bd1c7f0041160ea15ea2765df10194a6e9ef3e6e2139c11fc67f
(which seems to be incorrect), and contents of same file on repo clone is correct (equals to b675b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491
).
We replaced contents of file b6/75/b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491
on server with contents of this file from repo clone, and all is ok now.
We can do pull and push and change branches in new clones now without any errors.
To get sha256 on xubuntu we used
cat b6/75/b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491 | sha256sum
And on mac:
shasum -a 256 b6/75/b675b00828707cd53dc5c130efce8a9d352e5efd8b9b29f06808810b6ebb5491
Upvotes: 1