git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Setting up Git Server over SSH

From
Shawn Pearce <spearce@spearce.org>
Date
Nov 15, 2010, 18:38 UTC
Message-ID
<AANLkTimF2N-rYFYjOMm5kRRqRueLnmzJGpUoaCK3jsAC@mail.gmail.com>
In-Reply-To
<B99C7057496B47E48E5ABED7DE6BA51A@denny>
On Mon, Nov 15, 2010 at 10:20 AM, Dennis <dennisfm@friendlymatch.com> wrote:
Show 6 quoted lines
> I am doing this, but it fails:
>
>> git clone ssh://hostname.com:/home/user/.git
>
> Cloning into user...
> fatal: protocol error: bad line length character: logi

This looks to me like your server is echoing back text upon login. That text is being confused for Git protocol data by the Git client, but its not as expected, so it aborts with an error message.

Try getting the simple case to work first:
  ssh hostname.com echo hello

This should *only* print "hello". If it prints anything else (and right now I suspect it prints "login ..."), that will confuse Git. You need to adjust your server's shell login scripts to stop echoing information during a non-interactive shell. Or you may need to adjust your SSH client to ensure the authentication proceeds smoothly. Those "Access denied" errors look like you aren't actually authenticating to the server.

-- 
Shawn.
Previous: DennisNext: Dennis
Message 2 of 5 in “Setting up Git Server over SSH”
  1. DennisNov 15, 2010
  2. Shawn PearceNov 15, 2010
  3. DennisNov 15, 2010
  4. Ævar Arnfjörð BjarmasonNov 16, 2010
  5. DennisNov 17, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.