首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Gitlab升级错误init.d目录或文件问题

问Gitlab升级错误init.d目录或文件问题
EN

Stack Overflow用户
提问于 2013-10-18 00:42:30
回答 1查看 2.5K关注 0票数 4

为什么我会得到这个错误?

在6.4美分上将Git 5.4升级到6.0

已遵循升级指南https://github.com/gitlabhq/gitlabhq/blob/master/doc/update/5.4-to-6.0.md

完成后,我试着盯着我看

正在启动GitLab Unicorn web服务器...

代码语言:javascript
复制
/etc/init.d/gitlab: line 131: script/web: No such file or directory

正在启动GitLab Sidekiq事件调度程序...

代码语言:javascript
复制
/etc/init.d/gitlab: line 139: script/background_jobs: No such file or directory

GitLab未运行。

在init.d gitlab文件中

代码语言:javascript
复制
+    119 # Starts Unicorn and Sidekiq.  
+    120 start() {  
+    121   check_stale_pids  
+    122   
+    123   # Then check if the service is running. If it is: don't start again.  
+    124   if [ "$web_status" = "0" ]; then  
+    125     echo "The Unicorn web server already running with pid $wpid, not restarting."  
+    126   else  
+    127     echo "Starting the GitLab Unicorn web server..."  
+    128     # Remove old socket if it exists  
+    129     rm -f "$socket_path"/gitlab.socket 2>/dev/null  
+    130     # Start the webserver  
+    131     RAILS_ENV=$RAILS_ENV script/web start  
+    132   fi  
+    133   
+    134   # If sidekiq is already running, don't start it again.  
+    135   if [ "$sidekiq_status" = "0" ]; then    
+    136     echo "The Sidekiq job dispatcher is already running with pid $spid, not restarting"  
+    137   else    
+    138     echo "Starting the GitLab Sidekiq event dispatcher..."  
+    139     RAILS_ENV=$RAILS_ENV script/background_jobs start  
+    140     # We are sleeping a bit here because sidekiq is slow at writing it's pid  
+    141     sleep 2  
+    142   fi  
EN

回答 1

Stack Overflow用户

发布于 2013-10-18 17:44:18

您可能正在尝试使用较新版本的init脚本(例如,您的gitlab版本是6.0,并且您使用的是6.2中的init脚本)

尝试从已安装的版本复制init.d脚本的原始版本。通过root进入控制台:

代码语言:javascript
复制
cp {GITLAB_HOME}/gitlab/lib/support/init.d/gitlab /etc/init.d/gitlab && chmod 755 /etc/init.d/gitlab && /etc/init.d/gitlab start

当然,将{GITLAB_HOME}更改为安装gitlab的位置。

票数 6
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/19432532

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档