When I run 'vagrant up', I am getting below errors. I haven't any idea. Previously I was run without error. I sold SSD Harddisk and took it. When I want setup again, encountered this 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>'
The important part of that error is here:
No such file or directory @ rb_sysopen - /Users/KerimCaglar/KerimCaglar/.ssh/id_rsa
You either haven't generated your SSH key or you need to specify the correct path.
If you look at your Homestead.yaml
file you should see the path to your ssh key:
authorize: ~/.ssh/id_rsa.pub
keys:
- ~/.ssh/id_rsa
If your SSH key is somewhere else you'll need to specify the correct path. Otherwise you'll need to generate it.
ssh-keygen -t rsa -C "[email protected]"
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 have found this to be caused by:
Specifying too much path in the Vagrantfile, e.g.
config.vm.provision "file", source: "KerimCaglar/.ssh/id_rsa", destination: ".ssh/rd_rsa"
You're invoking vagrant up
from a subdirectory - cd ..; vagrant up
will fix it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With