大网数据广告活动
服务器运维问答

GitLab Runner failing to register after migration to new cluster

· 52CE 我爱测

I have GitLab installed in Kubernetes with their Helm chart. I migrated my old Gitlab deployment from one cluster to another with the following steps: Scale down all pods in old cluster Apply values.yml with helm to new cluster (…

问题原文

原帖链接 · cclloyd · CC BY-SA 4.0

I have GitLab installed in Kubernetes with their Helm chart.

I migrated my old Gitlab deployment from one cluster to another with the following steps:

  • Scale down all pods in old cluster
  • Apply values.yml with helm to new cluster (to create PVCs)
  • Scale down all pods in new cluster
  • Change DNS records, HAProxy, etc
  • Manually rsync data from old PVCs to new PVCs (minio, gitaly, redis, postgres, prometheus)
  • Run helm upgrade to bring deployments back online in new cluster

After all that the deployment for the most part works fine. Able to login and use git.

But the runner is failing to register, so I can't run any CI. Looking at the gitlab-gitlab-runner pod, I see the message below repeated over and over:

Registration attempt 30 of 30
Runtime platform                                    arch=amd64 os=linux pid=691 revision=3b6f852e version=14.0.0
WARNING: Running in user-mode.
WARNING: The user-mode requires you to manually start builds processing:
WARNING: $ gitlab-runner run
WARNING: Use sudo for system-mode:
WARNING: $ sudo gitlab-runner...
 
ERROR: Registering runner... failed                 runner=y6ixJoR1 status=500 Internal Server Error
PANIC: Failed to register the runner. You may be having network problems.

As you can see, it's failing to register the runner. Trying to go to /admin/runners gives me a 500 error.

Where can I see more information as to why I am getting this 500 error?

已采纳解答

原帖链接 · Mikołaj Głodziak · CC BY-SA 4.0

It looks like you have restored data and configuration from the previous cluster, however you are missing the secrets on the new cluster. Here you can find a procedure, what should you do, when the secrets are lost. You can also find there:

In cases like CI/CD variables and runner authentication, you can experience unexpected behaviors, such as:

  • Stuck jobs.
  • 500 errors. #you got this error

See also similar problems:

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2021-07-09)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。