Gitorious fatal error on push

263 views
Skip to first unread message

hayde...@yahoo.com

unread,
Aug 9, 2011, 2:54:54 PM8/9/11
to gito...@googlegroups.com
When I try to push to my local Gitorious install I get the following output.

== Gitorious: ==========================================================
fatal error
========================================================================

fatal: The remote end hung up unexpectedly

I did find this other discussion.


I'm wondering if I have the same problem, but I don't know how to check or fix it. I ran ps -aux, but didn't know which process I was interested in. Here are all the processes that are running under the user git.

git       1747  0.0  1.3 193068 112476 ?       Sl   Aug08   0:45 poller
git      25803  0.0  1.3 182044 107224 ?       S    Aug02   0:00 /usr/bin/ruby /var/www/git.myserver.com/gitorious/script/git-daemon -d

According to the install tutorial by Chris Johansen that should be correct.

Bobby Kirchgessner

unread,
Aug 9, 2011, 3:25:07 PM8/9/11
to gito...@googlegroups.com
Can you take a look at the your log files (git auth and production) and post them here?
--
To post to this group, send email to gito...@googlegroups.com
To unsubscribe from this group, send email to
gitorious+...@googlegroups.com

hayde...@yahoo.com

unread,
Aug 9, 2011, 6:53:59 PM8/9/11
to gito...@googlegroups.com
Ah, OK. I didn't know what logs to look in, or where they were. All I could find at first were the apache2 logs.

I rotated gitorious_auth.log and production.log in order to start with a clean history. When I try to do a push, I still get the same error, and only gitorious_auth.log gets anything written to it. Here is what the log looks like for a single failed push.

I, [2011-08-09 15:43:13#8967]  INFO -- : Connection from "10.3.9.153 45393 22" (hmuhl): git-receive-pack 'sandwich/sandwich.git'
F, [2011-08-09 15:43:13#8967] FATAL -- : SocketError getaddrinfo: Name or service not known: /usr/lib/ruby/1.8/net/http.rb:560:in `initialize'
  /usr/lib/ruby/1.8/net/http.rb:560:in `open'
  /usr/lib/ruby/1.8/net/http.rb:560:in `connect'
  /usr/lib/ruby/1.8/timeout.rb:53:in `timeout'
  /usr/lib/ruby/1.8/timeout.rb:101:in `timeout'
  /usr/lib/ruby/1.8/net/http.rb:560:in `connect'
  /usr/lib/ruby/1.8/net/http.rb:553:in `do_start'
  /usr/lib/ruby/1.8/net/http.rb:548:in `start'
  /usr/lib/ruby/1.8/net/http.rb:440:in `start'
  /usr/local/bin/gitorious:63
 
The URL I'm pushing to is g...@git.myserver.com:sandwich/sandwich.git. This is the SSH URL that I see in the Gitorious web interface.

Reid Ellis

unread,
Aug 9, 2011, 9:16:17 PM8/9/11
to gito...@googlegroups.com
That looks similar to the error I got once when I misconfigured the server's name in gitorious.yml ...

Benjamin Podszun

unread,
Aug 10, 2011, 3:57:43 AM8/10/11
to gito...@googlegroups.com
On Wed, Aug 10, 2011 at 1:53 AM, hayde...@yahoo.com <hayde...@yahoo.com> wrote:
Ah, OK. I didn't know what logs to look in, or where they were. All I could find at first were the apache2 logs.

I rotated gitorious_auth.log and production.log in order to start with a clean history. When I try to do a push, I still get the same error, and only gitorious_auth.log gets anything written to it. Here is what the log looks like for a single failed push.

F, [2011-08-09 15:43:13#8967] FATAL -- : SocketError getaddrinfo: Name or service not known: /usr/lib/ruby/1.8

This is, as far as I can tell, a problem in name resolution. Check your gitorious configuration: You have two hostnames in there. One is used internally, by the gitorious script called from ssh, to do connect to the rails application (in other words: Everytime you push a script makes an http connection. Caught me off-guard the first time I learned that). It uses the hostname you specify in gitorious.yaml.

Make sure that this is correct _and_ resolveable from the machine. If it makes your life easier you could add an entry to the hosts file as well, to fake a DNS entry that somehow matches the rest of your infrastructure.

Ben

hayde...@yahoo.com

unread,
Aug 10, 2011, 1:46:00 PM8/10/11
to gito...@googlegroups.com
This solved the problem. Thanks.

This is an unofficial, proof-of-concept install, so there is no DNS record for this box. I just added the proper host name to /etc/hosts on the Gitorious box and it worked like a charm.

I think that's it. Everything should be working now.
Reply all
Reply to author
Forward
0 new messages