1
geew OP 顶上去 来人啊
|
2
orzfly 2014-06-11 16:17:24 +08:00
去 gitlab.oa.com 里看看 /home/git/.ssh/authorized_keys 有没有出现你的 public key,如果没有说明 gitlab 的 sidekiq 又挂了……
|
3
geew OP |
6
geew OP @orzfly ssh 的调试信息, 感觉不是ssh的问题
OpenSSH_5.9p1 Debian-5ubuntu1.4, OpenSSL 1.0.1 14 Mar 2012 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 19: Applying options for * debug2: ssh_connect: needpriv 0 debug1: Connecting to gitlab.oa.com [192.168.58.220] port 22. debug1: Connection established. debug1: identity file /home/geew/.ssh/id_rsa type 1 debug1: Checking blacklist file /usr/share/ssh/blacklist.RSA-2048 debug1: Checking blacklist file /etc/ssh/blacklist.RSA-2048 debug1: identity file /home/geew/.ssh/id_rsa-cert type -1 debug1: identity file /home/geew/.ssh/id_dsa type -1 debug1: identity file /home/geew/.ssh/id_dsa-cert type -1 debug1: identity file /home/geew/.ssh/id_ecdsa type -1 debug1: identity file /home/geew/.ssh/id_ecdsa-cert type -1 debug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.1p1 Ubuntu-2ubuntu2 debug1: match: OpenSSH_6.6.1p1 Ubuntu-2ubuntu2 pat OpenSSH* debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_5.9p1 Debian-5ubuntu1.4 debug2: fd 3 setting O_NONBLOCK debug1: SSH2_MSG_KEXINIT sent debug1: SSH2_MSG_KEXINIT received debug2: kex_parse_kexinit: ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1 debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,[email protected],[email protected],[email protected],[email protected],ssh-rsa,ssh-dss debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,[email protected],hmac-sha2-256,hmac-sha2-256-96,hmac-sha2-512,hmac-sha2-512-96,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,[email protected],hmac-sha2-256,hmac-sha2-256-96,hmac-sha2-512,hmac-sha2-512-96,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 debug2: kex_parse_kexinit: none,[email protected],zlib debug2: kex_parse_kexinit: none,[email protected],zlib debug2: kex_parse_kexinit: debug2: kex_parse_kexinit: debug2: kex_parse_kexinit: first_kex_follows 0 debug2: kex_parse_kexinit: reserved 0 debug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1 debug2: kex_parse_kexinit: ssh-rsa,ssh-dss,ecdsa-sha2-nistp256,ssh-ed25519 debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 debug2: kex_parse_kexinit: none,[email protected] debug2: kex_parse_kexinit: none,[email protected] debug2: kex_parse_kexinit: debug2: kex_parse_kexinit: debug2: kex_parse_kexinit: first_kex_follows 0 debug2: kex_parse_kexinit: reserved 0 debug2: mac_setup: found hmac-md5 debug1: kex: server->client aes128-ctr hmac-md5 none debug2: mac_setup: found hmac-md5 debug1: kex: client->server aes128-ctr hmac-md5 none debug1: sending SSH2_MSG_KEX_ECDH_INIT debug1: expecting SSH2_MSG_KEX_ECDH_REPLY debug1: Server host key: ECDSA 0b:7d:a7:02:8c:c1:74:a2:f6:0b:9f:9a:e1:76:0a:08 debug1: Host 'gitlab.oa.com' is known and matches the ECDSA host key. debug1: Found key in /home/geew/.ssh/known_hosts:1 debug1: ssh_ecdsa_verify: signature correct debug2: kex_derive_keys debug2: set_newkeys: mode 1 debug1: SSH2_MSG_NEWKEYS sent debug1: expecting SSH2_MSG_NEWKEYS debug2: set_newkeys: mode 0 debug1: SSH2_MSG_NEWKEYS received debug1: Roaming not allowed by server debug1: SSH2_MSG_SERVICE_REQUEST sent debug2: service_accept: ssh-userauth debug1: SSH2_MSG_SERVICE_ACCEPT received debug2: key: /home/geew/.ssh/id_rsa (0x7fcb38067680) debug2: key: /home/geew/.ssh/id_dsa ((nil)) debug2: key: /home/geew/.ssh/id_ecdsa ((nil)) debug1: Authentications that can continue: publickey,password debug1: Next authentication method: publickey debug1: Offering RSA public key: /home/geew/.ssh/id_rsa debug2: we sent a publickey packet, wait for reply debug1: Server accepts key: pkalg ssh-rsa blen 279 debug2: input_userauth_pk_ok: fp cf:8c:28:26:82:a7:18:44:e4:ee:d8:db:a0:cd:0e:12 debug1: Authentication succeeded (publickey). Authenticated to gitlab.oa.com ([192.168.58.220]:22). debug1: channel 0: new [client-session] debug2: channel 0: send open debug1: Requesting [email protected] debug1: Entering interactive session. debug1: Remote: Forced command. debug1: Remote: Port forwarding disabled. debug1: Remote: X11 forwarding disabled. debug1: Remote: Agent forwarding disabled. debug1: Remote: Pty allocation disabled. debug1: Remote: Forced command. debug1: Remote: Port forwarding disabled. debug1: Remote: X11 forwarding disabled. debug1: Remote: Agent forwarding disabled. debug1: Remote: Pty allocation disabled. debug2: callback start debug2: client_session2_setup: id 0 debug2: fd 3 setting TCP_NODELAY debug2: channel 0: request pty-req confirm 1 debug1: Sending environment. debug1: Sending env LC_PAPER = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_ADDRESS = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_MONETARY = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_NUMERIC = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_TELEPHONE = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_IDENTIFICATION = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LANG = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_MEASUREMENT = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_TIME = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug1: Sending env LC_NAME = zh_CN.UTF-8 debug2: channel 0: request env confirm 0 debug2: channel 0: request shell confirm 1 debug2: callback done debug2: channel 0: open confirm rwindow 0 rmax 32768 debug2: channel_input_status_confirm: type 100 id 0 PTY allocation request failed on channel 0 debug2: channel 0: rcvd adjust 2097152 debug2: channel_input_status_confirm: type 99 id 0 debug2: shell request accepted on channel 0 Welcome to GitLab, Anonymous! debug1: client_input_channel_req: channel 0 rtype exit-status reply 0 debug1: client_input_channel_req: channel 0 rtype [email protected] reply 0 debug2: channel 0: rcvd eow debug2: channel 0: close_read debug2: channel 0: input open -> closed debug2: channel 0: rcvd eof debug2: channel 0: output open -> drain debug2: channel 0: obuf empty debug2: channel 0: close_write debug2: channel 0: output drain -> closed debug2: channel 0: rcvd close debug2: channel 0: almost dead debug2: channel 0: gc: notify user debug2: channel 0: gc: user detached debug2: channel 0: send close debug2: channel 0: is dead debug2: channel 0: garbage collecting debug1: channel 0: free: client-session, nchannels 1 Connection to gitlab.oa.com closed. Transferred: sent 3528, received 3112 bytes, in 0.4 seconds Bytes per second: sent 8723.7, received 7695.0 debug1: Exit status 0 |
7
orzfly 2014-06-11 17:36:07 +08:00 via Android
应该是 Welcome 后面有你的名字,而不是匿名。
你看看 gitlab (和 gitlab-shell)的日志 我记得有个 /api/xxxxx/internal/xxxxxxx 的请求会用来鉴权。这个请求如果失败就会匿名。 |
8
geew OP @orzfly 是这个吗
./production.log:Started PUT "/api/v3/authorizations/clients/eac522c6b68c504b2aac" for 127.0.0.1 at 2014-06-11 16:28:21 +0800 ./production.log:ActionController::RoutingError (No route matches [PUT] "/api/v3/authorizations/clients/eac522c6b68c504b2aac"): ./production.log:Started PUT "/api/v3/authorizations/clients/eac522c6b68c504b2aac" for 127.0.0.1 at 2014-06-11 16:28:22 +0800 ./production.log:ActionController::RoutingError (No route matches [PUT] "/api/v3/authorizations/clients/eac522c6b68c504b2aac"): ./production.log:Started PUT "/api/v3/authorizations/clients/eac522c6b68c504b2aac" for 127.0.0.1 at 2014-06-11 16:29:56 +0800 ./production.log:ActionController::RoutingError (No route matches [PUT] "/api/v3/authorizations/clients/eac522c6b68c504b2aac"): ./production.log:Started PUT "/api/v3/authorizations/clients/eac522c6b68c504b2aac" for 127.0.0.1 at 2014-06-11 16:29:56 +0800 ./production.log:ActionController::RoutingError (No route matches [PUT] "/api/v3/authorizations/clients/eac522c6b68c504b2aac"): |
9
orzfly 2014-06-11 18:31:28 +08:00 1
我这边通过 SSH 登陆的时候,production.log 里会出现一条:
Started GET "//api/v3/internal/discover?key_id=16" for 127.0.0.1 at 2014-06-11 18:30:37 +0800 |