Geo: Error fetching data in replicables view
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Summary
When clicking on a component on the Geo dashboard to see the replicables view, the replicables view throws an error There was an error fetching the projects_repositories.
The page also shows a message saying there are no project repositories to show and the list of replicated projects is not shown.
Steps to reproduce
Not sure how the installation get itself into this state and therefore not able to define reproduction steps.
The installation got itself into this state after a recent upgrade from 16.4.x to 16.5.0.
Example Project
What is the current bug behavior?
Fails to display the list of replicable objects for all components.
What is the expected correct behavior?
Show a list of replicable objects and their respective states for all components
Relevant logs and/or screenshots
Screenshot of replicables view for project repositories.

Noticed the following error in the geo.log on the primary site.
==> /var/log/gitlab/gitlab-rails/geo.log <== {"severity":"ERROR","time":"2023-10-31T13:14:33.995Z","correlation_id":"01HE2XY7HM0YJ2P3ZMH6JJXDWS","class":"Geo::GraphqlRequestService","gitlab_host":"34.107.86.155","message":"Could not connect to Geo primary node - HTTP Status Code: 500 Internal Server Error"}
Output of checks
Output of `gitlab-rake gitlab:geo:check on
Primary:
Checking Geo ... Finished `
Secondary:
Results of GitLab environment info
Expand for output related to GitLab environment info
(For installations with omnibus-gitlab package run and paste the output of: `sudo gitlab-rake gitlab:env:info`) (For installations from source run and paste the output of: `sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production`)
Results of GitLab application Check
Expand for output related to the GitLab application check
(For installations with omnibus-gitlab package run and paste the output of:
sudo gitlab-rake gitlab:check SANITIZE=true)(For installations from source run and paste the output of:
sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production SANITIZE=true)(we will only investigate if the tests are passing)
Possible fixes
- When the
rake gitlab:geo:checktask is run on the primary site, make it do a HTTP connection check against every secondary site. We already do the reverse check in the task (the secondary site checks that it can connect to the primary site), so much of the code already exists. - Add to the error message
There was an error fetching the X. Run the Geo check Rake task on the primary site, see https://docs.gitlab.com/ee/administration/geo/replication/troubleshooting/common.html#health-check-rake-task

