Gitlab库已损坏前端显示500错误解决方法
1.问题起因
办公网机房意外断掉,导致gitlab库文件损坏。开发打开gitlab显示500

2.查看日志
命令查看:gitlab-ctl tail
或者手动查看:/var/log/gitlab/gitlab-rails/production.log日志文件
gitlab Rugged::OdbError (Failed to inflate loose object.)
提示库文件损坏

3.处理方法
参考链接:
执行以下步骤后,库恢复正常
. # cd gitlab/repositories/<namespace>/<reponame>.git . # git fsck
If any error like below
error: object file objects//fbf0dfb1a54283e84044b5e99230efbafd77d8 is empty
error: object file objects//fbf0dfb1a54283e84044b5e99230efbafd77d8 is empty
fatal: loose object 11fbf0dfb1a54283e84044b5e99230efbafd77d8 (stored in objects//fbf0dfb1a54283e84044b5e99230efbafd77d8) is corrupt . # find . –size –delete
This will delete all files which has byte size and corrupt . # git fsck
Checking object directories: % (/), done.
Checking objects: % (/), done.
error: HEAD: not a commit
error: refs/heads/master: not a commit
dangling commit de516dd3d99d13147b6e2f946fe5b8c0660e4eed . Try to push code from local without add and commit
# git push origin <branch>
If got below error
remote: error: Could not read 5329f756010fad47026f112dc7126bdaa2f9ad7f
remote: fatal: Failed to traverse parents of commit 8eecd866caa916a3b2e8550153f0bb5a54a28919
remote: aborting due to possible repository corruption on the remote side.
fatal: protocol error: bad pack header . Go to cd gitlab/repositories/<namespace>/<reponame>.git
# rm –fr ref/head/<branchname>
# git fsck
notice: HEAD points to an unborn branch (master)
Checking object directories: % (/), done.
notice: No default references
dangling commit eb84ebc9010ea3d3d5646b4eab1bacd358178fbd . Try to push code from local without add and commit
# git push origin <branch> Done your code updated successfully !!!
Gitlab库已损坏前端显示500错误解决方法的更多相关文章
- 【Linux】Gitlab库已损坏前端显示500错误解决方法
背景: 在进行gitlab数据迁移之后,所有页面正常访问,唯独在访问项目repo地址时,报500错误 1 查看日志: 命令查看: gitlab-ctl tail 或者手动查看:/var/log/git ...
- WORDPRESS 后台500错误解决方法集合
引自: http://www.guuglc.com/565.html 这篇文章本质上我是不可能会写到,就因为7号那天晚上,我准备搬家的时候,发现前台完好,进入后台却500错误. 这时我就得急的,毕竟明 ...
- Axure RP chrome插件显示已损坏或者无法安装的解决方法
http://www.cnplugins.com/zhuanti/arux-rp-bug.html 1.Axure RP chrome插件无法安装的解决方法. 首先Axure RP chrome插件的 ...
- C#报Lc.exe已退出 代码为-1 错误解决方法
解决方法一:用记事本打开*.licx,里面写的全是第三方插件的指定DLL,删除错误信息,保存,关闭,重新生成解决方案. 解决方法二:把项目文件夹下Properties文件夹下的licenses.lic ...
- IIS前端页面不显示详细错误解决方法
要想解决这个问题,有三种方法可以考虑: 1.Internet信息服务(IIS)管理器 2.Web.config文件 3. 命令行 在IIS的"错误页"右边的"编辑功能设置 ...
- APACHE服务器500错误解决方法
1.APACHE没开启rewrite模块. 解决办法:编辑apache的http.conf文件,找到#LoadModule rewrite_module modules/mod_rewrite.so, ...
- idea运行Tomcat的servlet程序时报500错误解决方法
今天在测试使用Tomcat运行servlet小程序时,在传递参数时,出现了如上错误. 开始我以为是配置出了问题,就把项目删除了又建立了一遍,结果亦然. 经过仔细排查,发现问题,先说明问题原因:idea ...
- copy "xxxxx\xx.dll xxxxxxx\ ” 已退出,代码为1 错误解决方法
右键=>属性=>生成事件里面,查看预先生成事件命令行和后期生成事件命令行,查看复制的Dll是否存在已经路径是否正确
- ASP 500错误解决方法
最有效的解决方法: 经 c:\windows\temp 目录增加everyone写权限. 环境: windows2008
随机推荐
- window下nginx负载均衡简单配置-----权重的实现
下面介绍一个在window下的nginx的负载均衡配置. 需要你在你的电脑上跑两个tomcat.一个8080,一个9080. 需要一个nginx服务器. 需要修改本机的host 注意:我们这里配置不会 ...
- golang数组排序算法
冒泡排序 图 https://www.cnblogs.com/onepixel/articles/7674659.html package main import ( "fmt" ...
- Cmder-控制台模拟器
Cmder是一个软件包,由于在Windows上缺少漂亮的控制台模拟器而纯粹受挫. 它基于令人惊叹的软件,并采用Monokai配色方案和自定义快速布局,从一开始就看起来很性感. 首先,展示一下界面,和W ...
- vue项目中安装使用echarts
安装:cnpm install echarts -S (安装依赖并引入到 package.json) 官网安装说明:http://echarts.baidu.com/tutorial.html#%E5 ...
- C# Winform继承窗体打开设计器白屏的一例解决方法
环境VS2017 15.5.4,Win10开发过程中,发现一些窗体打开设计器会卡死白屏,另外有一些不会,(两者运行时正常),最小化vs后甚至能把工具箱连带搞黑,严重影响开发效率,经过一天多的对比研究, ...
- 15. Spring boot CRUD
一.列表页 templates/emp/list.html 0.侧边栏链接: <li class="nav-item"> <a class="nav-l ...
- 网络类型IPv4和IPv6什么意思?区别?
在windows 7以上系统中,在设置本地IP地址的时候经常会看到同事含有IPV4协议项与IPV6协议项,并不同于以往windows xp系统中仅有TCP/IP协议项,不少朋友都觉得比较奇怪,询问编辑 ...
- luogu 4158 粉刷匠 dp套dp
dp套dp 每个木板是个递推的dp,外部是个分组背包 #include<bits/stdc++.h> #define rep(i,x,y) for(register int i=x;i&l ...
- 实现一个string类
实现要实现:构造,析构,拷贝构造,赋值的功能 1. 提供构造函数 string(), string(const string & str),string(const char * str), ...
- C# 面向对象的new关键字的使用
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Cons ...