SSH connection issue when vagrant up

Getting ssh issue when ‘vagrant up’. The Error still persists after vagrant destroy then vagrant up.

DEBUG ssh: Checking whether SSH is ready…
DEBUG ssh: Checking key permissions: /data/vagrant_d/insecure_private_key
INFO ssh: Attempting SSH connection…
INFO ssh: Attempting to connect to SSH…
INFO ssh: - Host: 192.168.1.2
INFO ssh: - Port: 22
INFO ssh: - Username: vagrant
INFO ssh: - Password? false
INFO ssh: - Key Path: [“/data/vagrant_d/insecure_private_key”]
DEBUG ssh: - connect_opts: {:auth_methods=>[“none”, “hostbased”, “publickey”], :config=>false, :forward_agent=>true, :send_env=>false, :keys_only=>true, :verify_host_key=>:never, :password=>nil, :port=>22, :timeout=>15, :user_known_hosts_file=>, :verbose=>:debug, :logger=>#<Logger:0x00007f9d4233b058 @level=0, @progname=nil, @default_formatter=#<Logger::Formatter:0x00007f9d4233b008 @datetime_format=nil>, @formatter=nil, @logdev=#<Logger::LogDevice:0x00007f9d4233afb8 @shift_period_suffix=nil, @shift_size=nil, @shift_age=nil, @filename=nil, @dev=#StringIO:0x00007f9d4233b0d0, @mon_mutex=#Thread::Mutex:0x00007f9d4233af68, @mon_mutex_owner_object_id=70156698638300, @mon_owner=nil, @mon_count=0>>, :keys=>[“/data/vagrant_d/insecure_private_key”], :remote_user=>“vagrant”}
DEBUG ssh: == Net-SSH connection debug-level log START ==
DEBUG ssh: D, [2023-09-21T13:33:20.238767 #83218] DEBUG – net.ssh.transport.session[3fcea119c940]: establishing connection to 192.168.121.209:22
D, [2023-09-21T13:33:20.239235 #83218] DEBUG – net.ssh.transport.session[3fcea119c940]: connection established
I, [2023-09-21T13:33:20.239300 #83218] INFO – net.ssh.transport.server_version[3fcea119c120]: negotiating protocol version
D, [2023-09-21T13:33:20.239314 #83218] DEBUG – net.ssh.transport.server_version[3fcea119c120]: local is SSH-2.0-Ruby/Net::SSH_6.2.0.rc1 x86_64-linux-gnu' D, [2023-09-21T13:33:20.254476 #83218] DEBUG -- net.ssh.transport.server_version[3fcea119c120]: remote is SSH-2.0-OpenSSH_7.4’
I, [2023-09-21T13:33:20.254824 #83218] INFO – net.ssh.transport.algorithms[3fcea11cb8bc]: sending KEXINIT
D, [2023-09-21T13:33:20.254988 #83218] DEBUG – socket[3fcea119c5d0]: queueing packet nr 0 type 20 len 820
D, [2023-09-21T13:33:20.255057 #83218] DEBUG – socket[3fcea119c5d0]: sent 824 bytes
D, [2023-09-21T13:33:20.257798 #83218] DEBUG – socket[3fcea119c5d0]: read 1280 bytes
D, [2023-09-21T13:33:20.257875 #83218] DEBUG – socket[3fcea119c5d0]: received packet nr 0 type 20 len 1276
I, [2023-09-21T13:33:20.257906 #83218] INFO – net.ssh.transport.algorithms[3fcea11cb8bc]: got KEXINIT from server
I, [2023-09-21T13:33:20.257993 #83218] INFO – net.ssh.transport.algorithms[3fcea11cb8bc]: negotiating algorithms
D, [2023-09-21T13:33:20.258074 #83218] DEBUG – net.ssh.transport.algorithms[3fcea11cb8bc]: negotiated:

  • kex: ecdh-sha2-nistp521
  • host_key: ssh-ed25519
  • encryption_server: aes256-ctr
  • encryption_client: aes256-ctr
  • hmac_client: hmac-sha2-512-etm@openssh.com
  • hmac_server: hmac-sha2-512-etm@openssh.com
  • compression_client: none
  • compression_server: none
  • language_client:
  • language_server:
    D, [2023-09-21T13:33:20.258090 #83218] DEBUG – net.ssh.transport.algorithms[3fcea11cb8bc]: exchanging keys
    D, [2023-09-21T13:33:20.259007 #83218] DEBUG – socket[3fcea119c5d0]: queueing packet nr 1 type 30 len 148
    D, [2023-09-21T13:33:20.259059 #83218] DEBUG – socket[3fcea119c5d0]: sent 152 bytes
    D, [2023-09-21T13:33:20.268591 #83218] DEBUG – socket[3fcea119c5d0]: read 312 bytes
    D, [2023-09-21T13:33:20.268664 #83218] DEBUG – socket[3fcea119c5d0]: received packet nr 1 type 31 len 292
    D, [2023-09-21T13:33:20.270417 #83218] DEBUG – socket[3fcea119c5d0]: queueing packet nr 2 type 21 len 20
    D, [2023-09-21T13:33:20.270483 #83218] DEBUG – socket[3fcea119c5d0]: sent 24 bytes
    D, [2023-09-21T13:33:20.270542 #83218] DEBUG – socket[3fcea119c5d0]: received packet nr 2 type 21 len 12
    D, [2023-09-21T13:33:20.270770 #83218] DEBUG – net.ssh.authentication.session[3fcea11f6698]: beginning authentication of `vagrant’
    D, [2023-09-21T13:33:20.270817 #83218] DEBUG – socket[3fcea119c5d0]: using encrypt-then-mac
    D, [2023-09-21T13:33:20.270869 #83218] DEBUG – socket[3fcea119c5d0]: queueing packet nr 3 type 5 len 32
    D, [2023-09-21T13:33:20.270892 #83218] DEBUG – socket[3fcea119c5d0]: sent 100 bytes
    D, [2023-09-21T13:33:20.311099 #83218] DEBUG – socket[3fcea119c5d0]: read 100 bytes
    D, [2023-09-21T13:33:20.311198 #83218] DEBUG – socket[3fcea119c5d0]: received packet nr 3 type 6 len 32
    D, [2023-09-21T13:33:20.311268 #83218] DEBUG – net.ssh.authentication.session[3fcea11f6698]: trying none
    D, [2023-09-21T13:33:20.311331 #83218] DEBUG – socket[3fcea119c5d0]: using encrypt-then-mac
    D, [2023-09-21T13:33:20.311366 #83218] DEBUG – socket[3fcea119c5d0]: queueing packet nr 4 type 50 len 48
    D, [2023-09-21T13:33:20.311402 #83218] DEBUG – socket[3fcea119c5d0]: sent 116 bytes

DEBUG ssh: == Net-SSH connection debug-level log END ==
INFO ssh: SSH not up: #<Vagrant::Errors::NetSSHException: An error occurred in the underlying SSH library that Vagrant uses.
The error message is shown below. In many cases, errors from this
library are caused by ssh-agent issues. Try disabling your SSH
agent or removing some keys and try again.

If the problem persists, please report a bug to the net-ssh project.

1 Like