From: James Utter <james.utter@gmail.com>
To: git@vger.kernel.org
Subject: [Fwd: Re: strange git delays]
Date: Fri, 21 Mar 2008 11:32:59 +1100 [thread overview]
Message-ID: <1206059579.29416.26.camel@localhost> (raw)
On Thu, 2008-03-20 at 14:53 -0700, Linus Torvalds wrote:
>
> On Fri, 21 Mar 2008, James Utter wrote:
> >
> > james@timesink:~/testgit$ time git commit --message "initial commit"
> > Created initial commit 4f4b3a3: initial commit
> > 1 files changed, 1 insertions(+), 0 deletions(-)
> > create mode 100644 hello
> >
> > real 0m10.008s
> > user 0m0.000s
> > sys 0m0.008s
>
> Ok, that is almost exactly 10 seconds longer than it should take.
>
> And I can almost guarantee that it's something like a problem looking up
> your hostname or perhaps user identity - I would guess you have some name
> service problem.
>
> Do an
>
> strace -tT git commit --message "initial commit"
>
> on that git commit to make sure, but I would almost bet that it's when git
> does tget "getpwuid()" thing to get your name from the gecos fields, and
> you have some setup problem with nscd o similar.
>
> It might just go away if you set up your user name and email manually, ie
> try doing
>
> git config --global user.name "James Utter"
> git config --global user.email james.utter@gmail.com
>
> and see if that makes the delay go away. It probably tries to look up your
> login info from some non-existent NIS setup, and then times out after ten
> seconds and picks the data from your /etc/passwd file instead.
>
> (There can be other things that do similar things - misconfigured name
> servers etc can cause delay etc. So maybe I'm wrogn on blaming nscd, but
> it would be my first guess).
>
> Linus
It looks like you are right. Setting the git config --global settings
makes the problem disappear. I am not aware of (actively) setting up any
NIS, but there may be trouble in the DNS server.
>From the strace (attached):
10:55:34 sendto(3, "\307\304\1\0\0\1\0\0\0\0\0\0\ttimesink\n\5svana
\3net"..., 37, MSG_NOSIGNAL, NULL, 0) = 37 <0.000159>
10:55:34 poll([{fd=3, events=POLLIN}], 1, 5000) = 0 <4.995564>
10:55:39 poll([{fd=3, events=POLLOUT, revents=POLLOUT}], 1, 0) = 1
<0.000098>
10:55:39 sendto(3, "\307\304\1\0\0\1\0\0\0\0\0\0\ttimesink\n\5svana
\3net"..., 37, MSG_NOSIGNAL, NULL, 0) = 37 <0.000130>
10:55:39 poll([{fd=3, events=POLLIN}], 1, 5000) = 0 <4.999161>
10:55:44 close(3) = 0 <0.000111>
10:55:44 open("/etc/ld.so.cache", O_RDONLY) = 3 <0.000066>
Thank you,
James Utter
reply other threads:[~2008-03-21 0:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1206059579.29416.26.camel@localhost \
--to=james.utter@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.