Vagrant up returns 'open' : Access is denied. (5) (ChildProcess:: Error)

1,323 views
Skip to first unread message

Chris Buck

unread,
Jan 12, 2018, 12:59:23 PM1/12/18
to Vagrant
I am looking to have my team at work start using Vagrant to spin up lab environments for testing certain tools. To that end a DevOps (Mac) colleague of mine wrote a vagrant configuration for me. Vagrant spins up the two machines on his Mac, Windows fails.
My tech:
Windows 10 Anniversary Update
PowerShell 5
Vagrant 2.0.1
Virtualbox 5.2.2
Git 2.15.1.2
The etools Vagrant etc. were all installed using "Run as Administrator".

Whether I attempt to execute vagrant up as admin or using normal permissions in CMD, vagrant reports:

C:/HashiCorp/Vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/windows/handle.rb:12:in `open': Access is denied. (5) (ChildProcess::Error)
        from C:/HashiCorp/Vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/windows/process.rb:71:in `launch_process'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/abstract_process.rb:82:in `start'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/subprocess.rb:141:in `block in execute'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/safe_chdir.rb:26:in `block (2 levels) in safe_chdir'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/safe_chdir.rb:25:in `chdir'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/safe_chdir.rb:25:in `block in safe_chdir'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/safe_chdir.rb:24:in `synchronize'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/safe_chdir.rb:24:in `safe_chdir'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/subprocess.rb:140:in `execute'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/subprocess.rb:22:in `execute'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/powershell.rb:81:in `version'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/powershell.rb:95:in `validate_install!'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/powershell.rb:50:in `execute_cmd'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/platform.rb:73:in `block in windows_admin?'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/util/platform.rb:75:in `windows_admin?'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/plugins/providers/hyperv/provider.rb:19:in `usable?'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/environment.rb:379:in `block in default_provider'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/registry.rb:49:in `block in each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/registry.rb:48:in `each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/registry.rb:48:in `each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/environment.rb:365:in `default_provider'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/plugin/v2/command.rb:177:in `block in with_target_vms'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/plugin/v2/command.rb:204:in `block in with_target_vms'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/plugin/v2/command.rb:186:in `each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/plugin/v2/command.rb:186:in `with_target_vms'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/plugins/commands/up/command.rb:87:in `execute'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/cli.rb:42:in `execute'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/lib/vagrant/environment.rb:308:in `cli'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.0.1/bin/vagrant:138:in `<main>'

Almost laughably, when executing vagrant up from within PowerShell running as Admin, vagrant reports:

The version of powershell currently installed on this host is less than
the required minimum version. Please upgrade the installed version of
powershell to the minimum required version and run the command again.

  Installed version:
  Minimum required version: 3

Suggestions?

Alvaro Miranda Aguilera

unread,
Jan 12, 2018, 6:35:54 PM1/12/18
to vagra...@googlegroups.com
hello

this is strange:

C:/HashiCorp/Vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/windows/handle.rb:12:in `open': Access is denied. (5) (ChildProcess::Error)


as normal user using cmd.exe try with vagrant up --debug

bug use our default box first

mkdir precise64
cd precise64
vagrant init -m hashicorp/precise64
vagrant up

if this fails too add --debug

if this works then share the vagrantfile you are using and run vagrant up --debug and share the output


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/f0d92c57-00bf-4eb2-95b7-d369616acc57%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Kenneth Bowen

unread,
Mar 5, 2018, 11:22:34 AM3/5/18
to Vagrant
I'm having exactly this problem since upgrading to 2.0.2. I installed using Avecto Defendpoint 'Run with Elevated Privs', forced on me by corp IT. Has always worked in the past (2 years).

Tried, from a cmd.exe as a normal user:

vagrant init -m hashicorp/precise64
vagrant up --debug

...
DEBUG environment: Creating: C:/home/kbowen/dev/vagrant/test/.vagrant
 INFO environment: Running hook: environment_plugins_loaded
 INFO runner: Preparing hooks for middleware sequence...
 INFO runner: 2 hooks defined.
 INFO runner: Running action: environment_plugins_loaded #<Vagrant::Action::Builder:0x00000000045afd30>
 INFO environment: Running hook: environment_load
 INFO runner: Preparing hooks for middleware sequence...
 INFO runner: 2 hooks defined.
 INFO runner: Running action: environment_load #<Vagrant::Action::Builder:0x0000000004715f08>
DEBUG checkpoint_client: starting plugin check
 INFO cli: CLI: [] "up" []
DEBUG cli: Invoking command class: VagrantPlugins::CommandUp::Command []
DEBUG checkpoint_client: waiting for checkpoint to complete...
DEBUG checkpoint_client: plugin check complete
DEBUG checkpoint_client: no information received from checkpoint
DEBUG command: 'Up' each target VM...
 INFO loader: Set :root = ["#<Pathname:C:/home/kbowen/dev/vagrant/test/Vagrantfile>"]
DEBUG loader: Populating proc cache for #<Pathname:C:/home/kbowen/dev/vagrant/test/Vagrantfile>
DEBUG loader: Load procs for pathname: C:/home/kbowen/dev/vagrant/test/Vagrantfile
 INFO loader: Loading configuration in order: [:home, :root]
DEBUG loader: Loading from: root (evaluating)
DEBUG loader: Configuration loaded successfully, finalizing and returning
DEBUG push: finalizing
DEBUG command: Getting target VMs for command. Arguments:
DEBUG command:  -- names: ["default"]
DEBUG command:  -- options: {:provider=>nil}
DEBUG command: Finding machine that match name: default
 INFO loader: Set "36075340_machine_default" = []
 INFO loader: Loading configuration in order: [:home, :root, "36075340_machine_default"]
DEBUG loader: Loading from: root (cache)
DEBUG loader: Configuration loaded successfully, finalizing and returning
DEBUG push: finalizing
 INFO subprocess: Starting process: ["C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\/powershell.EXE", "-NoLogo", "-N
rofile", "-NonInteractive", "-ExecutionPolicy", "Bypass", "-Command", "Write-Output $PSVersionTable.PSVersion.Major"]
 INFO subprocess: Command not in installer, restoring original environment...
 INFO environment: Running hook: environment_unload
 INFO host: Autodetecting host type for [#<Vagrant::Environment: C:/home/kbowen/dev/vagrant/test>]
DEBUG host: Trying: alt
DEBUG host: Trying: arch
DEBUG host: Trying: darwin
DEBUG host: Trying: freebsd
DEBUG host: Trying: gentoo
DEBUG host: Trying: redhat
DEBUG host: Trying: slackware
DEBUG host: Trying: suse
DEBUG host: Trying: bsd
DEBUG host: Trying: linux
DEBUG host: Trying: null
DEBUG host: Trying: windows
 INFO host: Detected: windows!
 INFO runner: Preparing hooks for middleware sequence...
 INFO runner: 2 hooks defined.
 INFO runner: Running action: environment_unload #<Vagrant::Action::Builder:0x0000000004764068>
C:/apps/vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/windows/handle.rb:12:in `open': Access is denie
 (5) (ChildProcess::Error)
        from C:/apps/vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/windows/process.rb:71:in `launch_p
cess'
        from C:/apps/vagrant/embedded/gems/gems/childprocess-0.6.3/lib/childprocess/abstract_process.rb:82:in `start'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/subprocess.rb:141:in `block in execute'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/safe_chdir.rb:26:in `block (2 levels) i
safe_chdir'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/safe_chdir.rb:25:in `chdir'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/safe_chdir.rb:25:in `block in safe_chdi

        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/safe_chdir.rb:24:in `synchronize'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/safe_chdir.rb:24:in `safe_chdir'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/subprocess.rb:140:in `execute'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/subprocess.rb:22:in `execute'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/powershell.rb:88:in `version'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/powershell.rb:102:in `validate_install!
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/powershell.rb:57:in `execute_cmd'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/platform.rb:73:in `block in windows_adm
?'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/util/platform.rb:75:in `windows_admin?'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/plugins/providers/hyperv/provider.rb:19:in `usable?'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/environment.rb:340:in `block in default_prov
er'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/registry.rb:49:in `block in each'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/registry.rb:48:in `each'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/registry.rb:48:in `each'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/environment.rb:326:in `default_provider'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/plugin/v2/command.rb:177:in `block in with_t
get_vms'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/plugin/v2/command.rb:204:in `block in with_t
get_vms'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/plugin/v2/command.rb:186:in `each'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/plugin/v2/command.rb:186:in `with_target_vms
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/plugins/commands/up/command.rb:87:in `execute'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/cli.rb:46:in `execute'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/lib/vagrant/environment.rb:269:in `cli'
        from C:/apps/vagrant/embedded/gems/gems/vagrant-2.0.2/bin/vagrant:151:in `<main>'


To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+...@googlegroups.com.



--
Alvaro

Alvaro Miranda Aguilera

unread,
Mar 5, 2018, 12:01:07 PM3/5/18
to vagra...@googlegroups.com
due multiples variables is hard you hit the same issue as the other issue

so I will suggest send a new email and share information on your particular setup

same message doesnt mean will be the same cause

so better keep things separate




To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/ad56ba79-9c45-494a-b470-100d728931bc%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Kenneth Bowen

unread,
Mar 13, 2018, 10:38:52 AM3/13/18
to Vagrant
After installing on 3 different corporate Windows 8/10 boxes, I found a fix for me. 'vagrant up' always fails, but 'vagrant up --provider virtualbox' works. I couldn't see anything meaningful in the debug output with/without the switch, but it solve my problem. YMMV.

Best,

Kenneth

Alvaro Miranda Aguilera

unread,
Mar 13, 2018, 4:12:41 PM3/13/18
to vagra...@googlegroups.com
Hi


Does this happen with hashicorp/precise64 box?

if yes:

Can you open a issue on github and fill the template copy past your comment here since that hints where to look and please attach the full output of


vagrant up --debug

so looks like is failing to identify Virtualbox.


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Alvaro

Kenneth Bowen

unread,
Mar 13, 2018, 5:06:43 PM3/13/18
to Vagrant
Yes. Happens to all 12 devs on Win 8-10. It's probably related to Avecto Defendpoint, which we are forced to use when installing anything (elevated privs).
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+...@googlegroups.com.



--
Alvaro

Gabriel Lacerda

unread,
Mar 14, 2018, 10:57:01 AM3/14/18
to Vagrant
You did it mate! this is the fix for this problem, worked to me!

Kenneth Bowen

unread,
Jul 11, 2018, 4:45:10 PM7/11/18
to Vagrant
This worked up to vagrant version 2.0.2. Anything greater, including the latest 2.1.2, fails with the same error :(

Kevin Gigiano

unread,
Jul 25, 2018, 4:34:11 PM7/25/18
to Vagrant
Ken,

It is permissions related.

From a windows box, open whatever terminal program you are using (cmd, Powershell, Cygwin, etc) as an Administrator (Right click --> Run as administrator).

By the way, can you help me install Cygwin?......lol........ just kidding ;)

Kevin

Kenneth Bowen

unread,
Jul 25, 2018, 7:16:20 PM7/25/18
to Vagrant
Not helpful. You shouldn't have to run this as administrator - to do so is going to cause a bunch of other issues (can't manage the boxes via the virtbox gui, etc.).
Reply all
Reply to author
Forward
0 new messages