在sysprepping服务器之后,Git远程无法正常工作

时间:2012-04-27 19:27:19

标签: windows ssh gitolite openssh

所以,长话短说,我不小心编写了我的开发服务器,而不是我正在处理的虚拟机(我知道,因为新生儿而打开了太多的rdp窗口并且睡眠不足)。

开发服务器工作正常,我将机器名称更改回原来的状态并重新分配旧的IP地址。服务器上的其他所有内容似乎都可以工作,但我无法再远程连接到git。我认为它是gitolite或ssh相关。

git clone给了我: 连接由192.168.10.20关闭 致命:远程端意外挂断

这是我从ssh -v

获得的
OpenSSH_4.6p1, OpenSSL 0.9.8e 23 Feb 2007
debug1: Connecting to myserver [<serveripaddress>] port 22.
debug1: Connection established.
debug1: identity file /c/Users/me/.ssh/identity type -1
debug1: identity file /c/Users/me/.ssh/id_rsa type 1
debug1: identity file /c/Users/me/.ssh/id_dsa type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.8
debug1: match: OpenSSH_5.8 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.6
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host 'myserver' is known and matches the RSA host key.
debug1: Found key in /c/Users/me/.ssh/known_hosts:3
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: publickey
debug1: Trying private key: /c/Users/me/.ssh/identity
debug1: Offering public key: /c/Users/me/.ssh/id_rsa
Connection closed by <serveripaddress>

任何想法如何解决这个问题都非常感激。

1 个答案:

答案 0 :(得分:1)

有点像“Re: sshd: PID xxxx: fatal: initgroups: myid: Invalid argument.”,问题在于/etc/passwd/etc/group用户的SID错误(此处为“git”)

OP Ian1971评论:

  

问题是 sysprep会创建新的计算机ID ,因此/etc/passwd/etc/group中的所有本地Windows sid都出错了。