极狐GitLab 正式推出面向 GitLab 老旧版本(12.x、13.x、14.x、15.x 等)免费用户的专业升级服务,点击查看详情

返回列表 发布新帖

迁移后新建项目和打开设置,页面报500错误

334 3
发表于 2024-10-10 14:31:16 | 显示全部楼层 阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册

×

从原来的容器版,迁移到现在的Omnibus版后,点击新建项目或者设置就直接报错500。

使用gitlab-rake gitlab:doctor:secrets VERBOSE=1检查也都正常

具体报错如下:

Completed 500 Internal Server Error in 204ms (ActiveRecord: 19.0ms | Elasticsearch: 0.0ms | Allocations: 150769) {"method":"GET","path":"/projects/new","format":"html","controller":"ProjectsController","action":"new","status":500,"time":"2024-10-10T06:26:10.387Z","params":[],"remote_ip":"192.168.2.98","user_id":1,"username":"root","ua":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36","db_count":4,"db_write_count":0,"db_cached_count":1,"correlation_id":"xI0fPTA4Ff7","meta.user":"root","meta.caller_id":"ProjectsController#new","redis_calls":10,"redis_duration_s":0.001879,"redis_read_bytes":2254,"redis_write_bytes":1119,"redis_cache_calls":9,"redis_cache_duration_s":0.001488,"redis_cache_read_bytes":1745,"redis_cache_write_bytes":533,"redis_shared_state_calls":1,"redis_shared_state_duration_s":0.000391,"redis_shared_state_read_bytes":509,"redis_shared_state_write_bytes":586,"queue_duration_s":0.007835,"cpu_s":0.19,"exception.class":"NoMethodError","exception.message":"undefined method values' for nil:NilClass","exception.backtrace":["app/models/application_setting_implementation.rb:302:inblock in normalized_repository_storage_weights'","lib/gitlab/utils/strong_memoize.rb:30:in strong_memoize'","app/models/application_setting_implementation.rb:301:innormalized_repository_storage_weights'","app/models/application_setting_implementation.rb:314:in pick_repository_storage'","lib/gitlab/current_settings.rb:20:inmethod_missing'","app/models/concerns/has_repository.rb:23:in pick_repository_storage'","app/models/project.rb:72:inblock in class:Project'","app/models/project.rb:727:in initialize'","app/controllers/projects_controller.rb:54:innew'","app/controllers/application_controller.rb:497:in set_current_admin'","lib/gitlab/session.rb:11:inwith_session'","app/controllers/application_controller.rb:488:in set_session_storage'","app/controllers/application_controller.rb:482:inset_locale'","lib/gitlab/error_tracking.rb:51:in with_context'","app/controllers/application_controller.rb:547:insentry_context'","app/controllers/application_controller.rb:475:in block in set_current_context'","lib/gitlab/application_context.rb:52:inblock in use'","lib/gitlab/application_context.rb:52:in use'","lib/gitlab/application_context.rb:20:inwith_context'","app/controllers/application_controller.rb:468:in `set_current_context'"],"db_duration_s":0.01898,"view_duration_s":0.0,"duration_s":0.20392} Completed 500 Internal Server Error in 293ms (ActiveRecord: 1.8ms | Elasticsearch: 0.0ms | Allocations: 599357)

回复

使用道具 举报

评论3

wangkaixuanLv.7 发表于 2024-10-11 10:14:46 | 显示全部楼层
请确保下恢复的先决条件是否满足:https://gitlab.cn/docs/jh/raketa ... E%81%E7%8B%90gitlab

重点是gitlab-secret.json文件
回复

使用道具 举报

wysh1992楼主Lv.1 发表于 2024-10-11 13:23:54 | 显示全部楼层
wangkaixuan 发表于 2024-10-11 10:14
请确保下恢复的先决条件是否满足:https://gitlab.cn/docs/jh/raketasks/backup_restore.html#%E6%81%A2%E5 ...

gitlab-secret.json是手工恢复了的,MD5确认过一致
回复

使用道具 举报

wysh1992楼主Lv.1 发表于 2024-10-12 14:35:45 | 显示全部楼层
解决了,运行状况检查中给了非健康提示,执行建议命令gitlab-rails db:migrate RAILS_ENV=production后就正常了
回复

使用道具 举报

意见建议

Email:forum@gitlab.cn
  • 关注公众号
  • 添加专业顾问
Copyright © 2001-2024 极狐GitLab论坛 版权所有 All Rights Reserved. 鄂ICP备2021008419号-1|鄂公网安备42018502006137号
关灯 快速发帖
扫一扫添加专业顾问
返回顶部
快速回复 返回顶部 返回列表