The tramp does not work

When I run the "tramp up", I get below errors. I have no idea. I used to run without errors. I sold a Harddisk SSD and took it. When I want to install again, I encountered these errors.

/Users/KerimCaglar/sites/Homestead/scripts/homestead.rb:106:in `read': No such file or directory @ rb_sysopen - /Users/KerimCaglar/KerimCaglar/.ssh/id_rsa (Errno::ENOENT) from /Users/KerimCaglar/sites/Homestead/scripts/homestead.rb:106:in `block (2 levels) in configure' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/plugins/kernel_v2/config/vm_provisioner.rb:72:in `call' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/plugins/kernel_v2/config/vm_provisioner.rb:72:in `add_config' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/plugins/kernel_v2/config/vm.rb:321:in `provision' from /Users/KerimCaglar/sites/Homestead/scripts/homestead.rb:103:in `block in configure' from /Users/KerimCaglar/sites/Homestead/scripts/homestead.rb:102:in `each' from /Users/KerimCaglar/sites/Homestead/scripts/homestead.rb:102:in `configure' from /Users/KerimCaglar/sites/Homestead/Vagrantfile:20:in `block in <top (required)>' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/v2/loader.rb:37:in `call' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/v2/loader.rb:37:in `load' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/loader.rb:113:in `block (2 levels) in load' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/loader.rb:107:in `each' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/loader.rb:107:in `block in load' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/loader.rb:104:in `each' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/config/loader.rb:104:in `load' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/vagrantfile.rb:28:in `initialize' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:740:in `new' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:740:in `vagrantfile' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:486:in `host' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:208:in `block in action_runner' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/action/runner.rb:33:in `call' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/action/runner.rb:33:in `run' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:473:in `hook' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/environment.rb:722:in `unload' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/bin/vagrant:177:in `ensure in <main>' from /opt/vagrant/embedded/gems/gems/vagrant-1.8.1/bin/vagrant:177:in `<main>' 
+5
source share
3 answers

The important part of this error:

There is no such file or directory @rb_sysopen - / Users / KerimCaglar / KerimCaglar / .ssh / id_rsa

You either did not create your SSH key, or you need to specify the correct path.

If you look at your Homestead.yaml file, you will see the path to your ssh key:

 authorize: ~/.ssh/id_rsa.pub keys: - ~/.ssh/id_rsa 

If your SSH key is somewhere else, you need to specify the correct path. Otherwise, you will need to generate it.

 ssh-keygen -t rsa -C " your@email.com " 

Source

+22
source

The key part of the error is the duplicated path:

/Users/KerimCaglar/KerimCaglar/.ssh/id_rsa (Errno::ENOENT)

Notice how the username is mentioned twice. I found this to be caused by:

  • Specifying a too long path in a Vagrantfile, for example.

    config.vm.provision "file", source: " KerimCaglar /. ssh / id_rsa", destination: ".ssh / rd_rsa"

  • You call vagrant up from a subdirectory - cd ..; vagrant up cd ..; vagrant up fixes it.

+2
source

If you have Git installed, all you have to do is just generate your ssh key via the GUI. Help → Show Key

enter image description here

0
source

Source: https://habr.com/ru/post/1241945/


All Articles