升级gitlab到5.3之后pull出现下面的错误:
/usr/local/lib/ruby/1.9.1/net/protocol.rb:146:in `rescue in rbuf_fill': Timeout::Error (Timeout::Error)
from /usr/local/lib/ruby/1.9.1/net/protocol.rb:140:in `rbuf_fill'
from /usr/local/lib/ruby/1.9.1/net/protocol.rb:122:in `readuntil'
from /usr/local/lib/ruby/1.9.1/net/protocol.rb:132:in `readline'
from /usr/local/lib/ruby/1.9.1/net/http.rb:2562:in `read_status_line'
from /usr/local/lib/ruby/1.9.1/net/http.rb:2551:in `read_new'
from /usr/local/lib/ruby/1.9.1/net/http.rb:1319:in `block in transport_request'
from /usr/local/lib/ruby/1.9.1/net/http.rb:1316:in `catch'
from /usr/local/lib/ruby/1.9.1/net/http.rb:1316:in `transport_request'
from /usr/local/lib/ruby/1.9.1/net/http.rb:1293:in `request'
from /home/git/gitlab-shell/lib/gitlab_net.rb:56:in `block in get'
from /usr/local/lib/ruby/1.9.1/net/http.rb:745:in `start'
from /home/git/gitlab-shell/lib/gitlab_net.rb:56:in `get'
from /home/git/gitlab-shell/lib/gitlab_net.rb:17:in `allowed?'
from /home/git/gitlab-shell/lib/gitlab_shell.rb:51:in `validate_access'
from /home/git/gitlab-shell/lib/gitlab_shell.rb:21:in `exec'
from /home/git/gitlab-shell/bin/gitlab-shell:16:in `<main>'
fatal: Could not read from remote repository.
解决方案:
- 以root登录
- sudo service gitlab stop
- cd /home/git/gitlab
- rake gitlab:shell:setup RAILS_ENV=production
- 输入yes
- chown -R git /home/git/.ssh
- chgrp -R git /home/git/.ssh
- sudo service gitlab start
参考:http://www.linuxidc.com/Linux/2013-06/86544.htm
rake gitlab:shell:setup RAILS_ENV=production