Missed Team ’24? Catch up on announcements here.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Links to git repository no longer work after Bitbucket migration

Deleted user May 22, 2018

I recently migrated our Bitbucket server to a new machine. On the old machine, the path to the home directory was "/var/atlassian/application-data/bitbucket". Now it is one level shorter, namely "/var/atlassian/bitbucket".

In the web GUI, links and paths to repositories largely work, but for a couple of our branches / repos, we see errors similar to the following:

'/usr/bin/git cat-file -t regs/heads/python3-migration:' exited with code 0 saying: error: object directory /var/atlassian/application-data/bitbucket/shared/data/repositories/22/objects does not exist; check .git/objects/info/alternates.'

To me it looks like had-coded absolute paths are saved somewhere, either in the bitbucket db or home directory (which means I don't know whether it's Bitbucket saving the absolute paths or GIT.)

How do I set up my environment so that Bitbucket finds files relative to its home directory, as it should? Alternatively, do you have a list of where paths are hard-coded, so that I may go in and correct them myself?

1 answer

1 accepted

0 votes
Answer accepted
Prasanth
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 23, 2018

Hi Richard,

It seems that you are running in the the same scenario mentioned in object directory does not exist - Git operations fail. Forked repository of repository with ID 22 still refers to the old path /var/atlassian/application-data/bitbucket/shared/data/repositories/22/objects . "alternates" file available in BITBUCKET_HOME/shared/data/repositories/<repoID>/objects/info/alternates.

Please see the resolution section of above mentioned knowledge base article.

Hope this helps.

Regards,

Prasanth - Atlassian

Deleted user May 23, 2018

It does, indeed, help! Thanks for the info...

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events