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
随机推荐
- Spring 学习03
一.上节内容回顾 1 注解ioc操作 (1)使用注解创建对象 - 四个注解 (2)使用注解注入属性 - 两个注解 2 aop (1)aop原理 (2)aop术语 - 切入点 - 增强 - 切面 3 s ...
- linux系统中查看己设置iptables规则
1.iptables -L 查看filter表的iptables规则,包括所有的链.filter表包含INPUT.OUTPUT.FORWARD三个规则链. 说明:-L是--list的简写,作用是列出规 ...
- 作业引擎quartz.net --- 监听链
针对多个作业:如何描述各个跑批任务之间的顺序,紧前.紧后关系,实现灵活调度.例如:A完成则B开始,B完成C开始. 对quartz.net 进行了查阅,能实现如上业务,如下图: 测试代码: using ...
- C++ error LNK2001
1.没有函数的实现部分 2.函数的头文件和实现部分不一致 3.缺库LIB.DLL 4.库H文件函数和库体不一致
- android app与服务器交互
package mydemo.mycom.demo2.service; import org.apache.http.HttpResponse; import org.apache.http.Name ...
- 寻路优化(二)——二维地图上theta*算法的设计探索
这篇文章是基于上一篇文章的研究上进行的,使得路径更加的平滑和自然,特此记录.有错误欢迎大家批评指正.如需转载请注明出处,http://www.cnblogs.com/Leonhard-/p/68660 ...
- python manage.py syncdb Unknown command: 'syncdb'问题解决方法
在django1.9后的版本中,python manage.py syncdb命令修改为python manage.py migrate,执行正常. 选择sqlite可视化sqlitestudio-3 ...
- CentOS 7以上版本Nginx开机自启
Nginx+Center OS 7.x 开机启动设置 centos 7以上是用Systemd进行系统初始化的,Systemd 是 Linux 系统中最新的初始化系统(init),它主要的设计目标是克服 ...
- android AysncTask使用
1.继承AysncTask类 例子: class downloadTask extends AsyncTask<Void,Integer,Boolean> 第一个参数是传入的参数 第二个参 ...
- Latex graphicx 宏包 scalebox命令
scalebox 命令需要加载 \usepackage{graphicx} \scalebox{水平缩放因子}[垂直缩放因子]{对象} \scalebox 命令对其作用的对象进行缩放,使缩放后的对 ...