Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Git LFS files not found on server

We have been using Git with git-lfs hosted by our own instance of Gitlab.

Sometimes when one particular user pushes files, some of them (seems to be .png files) don't make it to the LFS storage, but are added to git. I haven't been able to see the log / messages when this happens yet on their machine.

But what ends up happening is when other users try to download that file from LFS, it throws an error:

[28bbec36fe441b7de97d566872c71cd4542384d871b369168285408c1f062cfd] Object does not exist on the server or you don't have permissions to access it

I have tried manually uploading a file in its place on the Gitlab server in the git-lfs data directory with the correct SHA ID for the file name, but it doesn't seem to get picked up. So far my only solution is to touch the file so it generates a different SHA ID, and re-upload it.

Is there any way to manually add an individual file to Gitlab's git-lfs storage?

like image 423
Blazing Avatar asked Jan 27 '16 22:01

Blazing


1 Answers

i guess that the git-lfs was not installed correctly on the clientside of the client pushing. However, if you have git-lfs 0.5.4 you should be able to fix it with following:

# git lfs push --object-id origin [oid] [oid] [oid]
$ git lfs push --object-id origin 28bbec36fe441b7de97d566872c71cd4542384d871b369168285408c1f062cfd
like image 195
Frossy Avatar answered Oct 19 '22 01:10

Frossy