-1

I'm running a version of GitLab that I installed last fall. Unfortunately I am unable to ascertain a version number. It is hosted on Ubuntu 1404 in a VM on a Win10 host. UPDATE: Looks to be rev 9.4.3-ce.0 and is the latest available from the Ubuntu package servers.

I am recovering from a disaster that necessitated a cold reinstall of Win10. I have the VM up and running in VirtualBox. My GitLab login credentials seem to work just fine - I can log into the server and I can clone my projects using http. What I cannot do is access the server via ssh. I should add that before the disaster everything worked just fine.

From msys bash I can ssh into the VM just fine, but all attempts to access GitLab via ssh elicit the following:

$ git push origin dev-5-1-0
fatal: 'git@elm-ub1404/xxx/program.git' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I have verified that the key in GitLab's Settings/ssh-keys is the correct one. I've even deleted it and then added it back, to no avail.

The log file, gitlab-shell.log, contains the following:

W, [2017-08-07T22:58:00.754776 #23099]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/program.git'> by user with key key-1.
W, [2017-08-07T23:03:07.060909 #23937]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/program.git'> by user with key key-1.
W, [2017-08-07T23:05:51.418158 #24333]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/pruProgram.git'> by user with key key-1.
W, [2017-08-07T23:08:33.799837 #24841]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/pruProgram.git'> by user with key key-1.
W, [2017-08-07T23:09:22.509888 #25006]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/pruProgram.git'> by user with key key-1.
W, [2017-08-07T23:13:57.921136 #25626]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git receive-pack 'user/pruProgram.git'> by user with key key-1.
W, [2017-08-07T23:19:01.909144 #26864]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git upload-pack 'user/pruProgram.git'> by user with key key-1.
W, [2017-08-07T23:22:22.732120 #27344]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git upload-pack 'user/pruProgram.git'> by user with key key-1.
I, [2017-08-07T23:44:11.110398 #30251]  INFO -- : Adding key key-2 => "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDITEDPYSbseUrbFW3Ii5dcKi6g4BJXi0U3yiK81NwXGcXGHMJCjlHNhblssetztc3xLuugK7syG+Sapt3kDvGzcOTi3NFrpYpv5y7RPlNVMBsgC+hSdsX3u6TZMuoSAByfgNK+DEkSGkgelrp6XIUWR4C4urLcxDqK7TFMM3xYF0JiE7t3lLRR7T8o+UY8gXozrmHyZout1CHpNv3OY9JDdj7V6+KjKAuVplJaqsx9zAh5sF7aGCUHUM5DESriLUjqgEgc+tZ4s31PPdgnhkX0Scm8M2405vnwLqIJ2a3qmpAwvOcM/rC/LTOJg4k7tjDtCEOr7v5usBNZwsUeiuuD"
W, [2017-08-07T23:48:40.016559 #30875]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git upload-pack 'user/pru6c.git'> by user with key key-1.
W, [2017-08-08T09:02:52.468088 #3630]  WARN -- : gitlab-shell: Attempt to execute disallowed command <git upload-pack 'user/pru6c.git'> by user with key key-1.
I, [2017-08-08T09:04:31.179381 #3828]  INFO -- : Removing key key-2
I, [2017-08-08T09:04:36.470186 #3852]  INFO -- : Removing key key-1
I, [2017-08-08T09:05:17.803599 #3942]  INFO -- : Adding key key-3 => "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDRFtPPqEGtCrgUHD+Q/WJcNKxOGm3h+paLQM9TOoDBQLG4HBb9cHoMPLEcX2USNy2TYaOIRQ8eCNu1O+E2u5RZWjG3rC35ygq5qu7LZH6Eed6vOGp5runWtyGsua3AQlJvu0FK247QeQaKnAmF77CqISW2ul0VDOp+Jw7KtfEf6r0smkkNEG7OpK5Cgjx7MZMNEN1Qsp8AzphcbLOTFNLR4oy+yMDUdtG9WDZEZKJmhpt0VeG1WAVHpxanLwza3fNG/Kwb2s6NolDD6CQAWaqM63wYh3HbU2m/S6kcLaAs1WDE0VIiVfIjoEMhnYVrcMKS6qAWYbjgJ7N5Dvq3JCXr"

For some reason my attempts to access the repo after deleting and replacing the original key (deleted key-1 and re-entered it as key-3) no longer elicit log messages in gitlab-shell.log.

When I do "ssh -Tv git@elm-ub1404, I get the following:

OpenSSH_7.5p1, OpenSSL 1.0.2k  26 Jan 2017
debug1: Reading configuration data /home/user/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Connecting to elm-ub1404 [192.168.55.230] port 22.
debug1: Connection established.
debug1: identity file /home/user/.ssh/id_rsa type 1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/user/.ssh/id_ed25519-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.5
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.8
debug1: match: OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.8 pat OpenSSH_6.6.1* compat 0x04000000
debug1: Authenticating to elm-ub1404:22 as 'git'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: [email protected]
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: [email protected] MAC: <implicit> compression: none
debug1: kex: client->server cipher: [email protected] MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:p7T0NBYGy8Jwuv1OH3bIvuykgiqypAxfUXoVtqQoh8Q
debug1: Host 'elm-ub1404' is known and matches the ECDSA host key.
debug1: Found key in /home/user/.ssh/known_hosts:23
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/user/.ssh/id_rsa
debug1: Server accepts key: pkalg ssh-rsa blen 279
debug1: Authentication succeeded (publickey).
Authenticated to elm-ub1404 ([192.168.55.230]:22).
debug1: channel 0: new [client-session]
debug1: Requesting [email protected]
debug1: Entering interactive session.
debug1: pledge: exec
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.
debug1: No xauth program.
Warning: No xauth data; using fake authentication data for X11 forwarding.
debug1: Requesting X11 forwarding with authentication spoofing.
debug1: Remote: X11 forwarding disabled in user configuration file.
X11 forwarding request failed on channel 0
Welcome to GitLab, Bob Duffy!
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
debug1: client_input_channel_req: channel 0 rtype [email protected] reply 0
debug1: channel 0: free: client-session, nchannels 1
Transferred: sent 2800, received 3080 bytes, in 2.3 seconds
Bytes per second: sent 1219.8, received 1341.7
debug1: Exit status 0

So my questions are:

  1. How do I get more information about the git-ssh connection?
  2. How do I regain ssh access to GitLab?

UPDATE:

Just to be sure, I am copying the repo references from the GitLab project page:

Elm-10:~/gitlabTest$ git clone git@elm-ub1404:rlduffy/program.git
Cloning into 'program'...
Warning: No xauth data; using fake authentication data for X11 forwarding.
X11 forwarding request failed on channel 0
GitLab: Disallowed command
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
Elm-10:~/gitlabTest$ git clone http://elm-ub1404/rlduffy/program.git
Cloning into 'program'...
remote: Counting objects: 4760, done.
remote: Compressing objects: 100% (24/24), done.
remote: Total 4760 (delta 8), reused 0 (delta 0)
Receiving objects: 100% (4760/4760), 3.09 MiB | 19.54 MiB/s, done.
Resolving deltas: 100% (3542/3542), done.
3
  • The initial message ins't about SSH access, but about the actual existence of the repository. Where was it hosted? In the VM storage or on some shared Windows directory?
    – xenoid
    Aug 9, 2017 at 11:09
  • The repo is stored in the VM. I can access it from Windows using git via http and I can use the web interface. But it fails using ssh.
    – rlduffy
    Aug 9, 2017 at 14:07
  • There is something wrong with your specified remote address, it should be git@host:/path/to.git - git@elm-ub1404:/xxx/program.git at least you miss colons
    – user759936
    Aug 10, 2017 at 6:55

1 Answer 1

-1

I suspect that the problem would resolve itself by uninstalling and reinstalling GitLab, but I'm not prepared to do that just now, so I'll just resort to using http instead.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .