Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have two servers, an older server running plain git with three repositories under /opt/. These projects are now to be moved over to a new server where I choose to run gitlab for the sake of the GUI and to be able to invite friends to learn programming and have an easier place to view and manage projects.

However, when moving over I want to keep the revisions of my old code bases. Somehow I thought just doing scp -r /gitlab/ would suffice but this fails.

I navigated to gitlab and created a new repo just to get the folder structure which created a wiki and a code-folder called /gitlab/project.git with the same folder structure as it is on the old server (without the code obviously) and the project loads fine in gitlab, but then i did rm -rf project.git and did the scp ... and now i get a 500 We're sorry, but something went wrong..

My guess is that the revisions and perhaps an URL in the server-folder is wrong, but I can't find anything by going through the files manually or via the docs on gitlab.

Anyone done something similar?

Thank you in advance!

share|improve this question

Add the new gitlab remote to your existing repository and push:

git remote add gitlab url-to-gitlab-repo

git push gitlab master

share|improve this answer
up vote 1 down vote accepted

Often the most simple basic solutions work... permissions, always check your permissions.

chown -R git.git /gitlab/project.git/
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.