vagrant-google icon indicating copy to clipboard operation
vagrant-google copied to clipboard

SSH keeps failing: dyld: lazy symbol binding failed: Symbol not found: _SHA512Init

Open peterlobster opened this issue 6 years ago • 2 comments

No matter how I seem to set up SSH it keeps failing with:

...
==> default: Waiting for SSH to become available...
DEBUG ssh: Checking whether SSH is ready...
 INFO machine: Calling action: read_ssh_info on provider Google (vagrant-box)
 INFO interface: Machine: action ["read_ssh_info", "start", {:target=>:default}]
 INFO runner: Preparing hooks for middleware sequence...
 INFO runner: 2 hooks defined.
 INFO runner: Running action: machine_action_read_ssh_info #<Vagrant::Action::Builder:0x000000010d261f98>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d250e50>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::ConfigValidate:0x000000010d250e28>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d250e00>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d250d88>
 INFO warden: Calling IN action: #<VagrantPlugins::Google::Action::ConnectGoogle:0x000000010d250d60>
 INFO connect_google: Creating Google API client and adding to Vagrant environment
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d219130>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d2190b8>
 INFO warden: Calling IN action: #<VagrantPlugins::Google::Action::ReadSSHInfo:0x000000010d219090>
 INFO warden: Calling IN action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d1e0cb8>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d1e0cb8>
 INFO warden: Calling OUT action: #<VagrantPlugins::Google::Action::ReadSSHInfo:0x000000010d219090>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d2190b8>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d219130>
 INFO warden: Calling OUT action: #<VagrantPlugins::Google::Action::ConnectGoogle:0x000000010d250d60>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d250d88>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::AfterTriggerAction:0x000000010d250e00>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::ConfigValidate:0x000000010d250e28>
 INFO warden: Calling OUT action: #<Vagrant::Action::Builtin::BeforeTriggerAction:0x000000010d250e50>
 INFO interface: Machine: action ["read_ssh_info", "end", {:target=>:default}]
DEBUG ssh: Checking key permissions: /Users/peter/.ssh/google_compute_engine
 INFO ssh: Attempting SSH connection...
 INFO ssh: Attempting to connect to SSH...
 INFO ssh:   - Host: 34.83.30.108
 INFO ssh:   - Port: 22
 INFO ssh:   - Username: peter
 INFO ssh:   - Password? false
 INFO ssh:   - Key Path: ["/Users/peter/.ssh/google_compute_engine"]
DEBUG ssh:   - connect_opts: {:auth_methods=>["none", "hostbased", "publickey"], :config=>false, :forward_agent=>false, :send_env=>false, :keys_only=>true, :verify_host_key=>:never, :password=>nil, :port=>22, :timeout=>15, :user_known_hosts_file=>[], :verbose=>:debug, :encryption=>["aes256-ctr", "aes192-ctr", "aes128-ctr", "aes256-cbc", "aes192-cbc", "aes128-cbc", "[email protected]", "blowfish-ctr", "blowfish-cbc", "cast128-ctr", "cast128-cbc", "3des-ctr", "3des-cbc", "idea-cbc", "arcfour256", "arcfour128", "arcfour", "none"], :logger=>#<Logger:0x000000010d112f98 @level=0, @progname=nil, @default_formatter=#<Logger::Formatter:0x000000010d112f48 @datetime_format=nil>, @formatter=nil, @logdev=#<Logger::LogDevice:0x000000010d112ed0 @shift_period_suffix=nil, @shift_size=nil, @shift_age=nil, @filename=nil, @dev=#<StringIO:0x000000010d113010>, @mon_owner=nil, @mon_count=0, @mon_mutex=#<Thread::Mutex:0x000000010d112e80>>>, :keys=>["/Users/peter/.ssh/google_compute_engine"], :remote_user=>"peter"}
dyld: lazy symbol binding failed: Symbol not found: _SHA512Init
  Referenced from: /opt/vagrant/embedded/gems/2.2.4/gems/bcrypt_pbkdf-1.0.0/lib/bcrypt_pbkdf_ext.bundle
  Expected in: flat namespace

dyld: Symbol not found: _SHA512Init
  Referenced from: /opt/vagrant/embedded/gems/2.2.4/gems/bcrypt_pbkdf-1.0.0/lib/bcrypt_pbkdf_ext.bundle
  Expected in: flat namespace

I've tried setting up my SSH with gcloud, manually, and even OS Login but I see to keep running into this.

Has this happened to anyone else? Can anyone offer any insight?

peterlobster avatar May 09 '19 19:05 peterlobster

Hmmm, looks like something is happening when one of the underlying libraries is trying to decrypt/read your ssh key.

Can you try doing ssh add on the key first, e.g. ssh-add ~/.ssh/id_rsa and retry?

Temikus avatar May 12 '19 03:05 Temikus

I had a different problem, when running with debug, ssh would not work from vagrant, but just fine in the terminal using the same user and same ssh key. I would get the error all authorization methods failed in vagrant when running with --debug.

ssh-add of my ssh key helped vagrant finish the process.

simonpie avatar Nov 29 '22 18:11 simonpie