Vagrant init fails to create Vagrantfile

When I run “vagrant init” on a Windows system, it does not create a Vagrantfile. I have permissions to create files in the directory. It does not give me an error or warning message. Any ideas? What troubleshooting steps should I take?


Hey there,
could you share the debug logs for this issue. It might provide some clues as to what is going wrong. Thanks!

This post was flagged by the community and is temporarily hidden.

vagrant_init_debug_logs.txt (33.5 KB)

I am also facing the same issue. Please don’t hide my comments this time.

$ vagrant.exe --version
Vagrant 2.2.14

attaching the debug logs.

From the logs, it looks like you have a Vagrantfile at C:/Users/Jinendra/Vagrantfile that is invalid. You can either remove the Vagrantfile, or remove the erroneous line.


Thanks. That was the culprit. But I wasn’t having that in my project directory. Why it was creating problem while initializing vagrant in a different path?

Vagrant should only be picking up the Vagrant file present in your current working director. So, I would expect the error to happen when running Vagrant from the directory C:/Users/Jinendra. Otherwise it should have no effect on Vagrant.