Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

machine with name 'default' not configured #102

Closed
xenoterracide opened this issue Jun 6, 2014 · 19 comments
Closed

machine with name 'default' not configured #102

xenoterracide opened this issue Jun 6, 2014 · 19 comments

Comments

@xenoterracide
Copy link

The machine with the name 'default' was not found configured for this Vagrant environment.

ok... why would I have a default configured? why does vagrant up error out because of this? what is the resolution?

probably worth noting that I do have a vm enabled by default. config.vm.define "oracle", primary: true do |oracle|

@gtd
Copy link

gtd commented Jun 30, 2014

I'm also getting this error on both vagrant up and vagrant destroy right after:

==> mubi: Updating /etc/hosts file on active guest machines...

I'm trying some clean setup steps to see if it goes away. Will update here if I find anything interesting...

@kensykora
Copy link
Contributor

The machine name needs to be the one that vagrant refers to it by -- Try running vagrant status and it should show you the name of the machine. Replace default with that machine name.

@ricoli
Copy link

ricoli commented Aug 28, 2014

check the folder ./.vagrant/machines, and delete the ones you no longer need

@danielbenzvi
Copy link

This is caused by obsolete machines that are still in the global Vagrant environment.
Clean it up by running vagrant global-status --prune

@thewinterwind
Copy link

@danielbenzvi nice

@rchadha
Copy link

rchadha commented Aug 19, 2015

Thanks @danielbenzvi . vagrant global-status --prune fixed the issue

@lorenzschmid
Copy link

@ricoli 's tipp deleting obsolete machines in ./.vagrant/machines did the trick for me, thank you!

@hazriqpedia
Copy link

@ricoli 's tip is the solution for me. Thanks!

@patrick-hill
Copy link

@danielbenzvi Thanks! Got a new alias now: alias vclean='vagrant global-status --prune'

@59023g
Copy link

59023g commented Apr 27, 2016

found related issue with same output #21

@mrtndwrd
Copy link

Would it be possible to include more explanation in the error message? e.g.

"The machine with the name 'default' was not found configured for this Vagrant environment. This might mean that you have old machines in the directory ./.vagrant/machines"

And maybe even add

"Try running vagrant global-status --prune to solve the issue"

@daryn-k
Copy link

daryn-k commented Dec 19, 2016

please help! vagrant global-status --prune didn't solve the problem!

@mbheemappa
Copy link

I had the same issue and vagrant global-status --prune din't work.
But later realized that there was an obseleted .vagrant directory, I just deleted that and reissued below command. It just Worked..!!

vagrant global-status --prune

@martinliu
Copy link

When I install DCOS local mode. I got same problem.

The machine with the name 'proxy' was not found configured for

I fixed issue and get DCOS vms up and running.

  • rm -rf .vagrant
  • vagrant global-status --prune
  • vagrant up

@daminduLiyanage
Copy link

daminduLiyanage commented Feb 18, 2018

After 3 days trying everything on a Windows machine these steps solved the problem:
(Received this error for the JetBrains PhpStorm, these are alternative steps to correct the problem in PhpStorm).
Prior to carrying out the following make sure the vagrant environment and if you are using the Homestead they are set up in the machine correctly. Instead of trying to get the instance from vagrant Homestead folder you can create a virtual default machine from the PhpStorm itself.

Goto Tools | vagrant | Init in project root
image
The terminal will open up and a machine named 'default' will be created.
Next, goto Toos | vagrant | up to bring the machine up.

If it gives you an error, telling it could not determine the machine state or something like that, like what happened in my case, then open up a separate terminal and run the command.
$ vagrant global-status --prune
It will refresh the state of global vagrant machine status.

Now go to Edit | Settings | Language & Frameworks | PHP then browse the CLI interpreter
Add interpreter with the + sign to select the 'From Docker, Vagrant, VM, Remote...' to open the vagrant 'configure Remote PHP Interpreter' dialog box
image
image
The instance folder should be your project folder, it will be there in the text box automatically.

In here, if it gives an error, informing ssh authentication failed, readd the remote interpreter again. It should solve the problem. Hope this helps!

@magentomaniac
Copy link

I also needed to remove folder in .vagrant/machines/

@tdensmore
Copy link

running vagrant global-status --prune gave me an error:

/Users/blah/workspace/quickstart/vagrant/Vagrantfile:28:in `fetch': key not found: "admin_password" (KeyError)
	from /Users/blah/workspace/quickstart/vagrant/Vagrantfile:28:in `block (2 levels) in <top (required)>'

Trying to delete images was not straightforward either:

I don't have a .vagrant folder. I do have a .vagrant.d folder. It doesn't contain machines, but does contain boxes. Deleting the files in this folder did not help.

@vrubiolo
Copy link

vrubiolo commented Oct 9, 2019

Just to confirm that vagrant global-status --prune also did the trick for me. I'd agree a better error message would be welcome as the user it left w/o a clue of what when wrong.

For the record, I had also encountered the issue after changing the machine name in the Vagrantfile.

Bringing machine 'test' up with 'libvirt' provider...
==> test: [vagrant-hostmanager:guests] Updating hosts file on active guest virtual machines...
The machine with the name 'nuancier' was not found configured for
this Vagrant environment.

@Maguod
Copy link

Maguod commented Mar 18, 2020

If you work in PHPStorm with php frameworks and in console have problem
"The machine with the name 'machine_name' was not found configured for
this Vagrant environment." In your project this be name machine http:https://joxi.ru/GrqWqY6Uk045R2
Remove. And use command "vagrant up" Good luck.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests