2017-07-11 54 views
0

的Windows 10流浪叉()函數在Windows未實現本機(NotImplementedError)上

當運行vagrant up,得到了這些錯誤:

==> centos: Destroying VM and associated drives... 
C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/daemonize.rb:10:in `fork': fork() function is unimplemented on this machine (NotImplementedError) 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/daemonize.rb:10:in `safefork' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/daemonize.rb:45:in `call_as_daemon' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/application.rb:270:in `start_proc' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/application.rb:296:in `start' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/controller.rb:56:in `run' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons.rb:197:in `block in run_proc' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/cmdline.rb:92:in `call' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons/cmdline.rb:92:in `catch_exceptions' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/daemons-1.2.4/lib/daemons.rb:196:in `run_proc' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-dns-1.1.0/lib/vagrant-dns/service.rb:26:in `run!' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-dns-1.1.0/lib/vagrant-dns/service.rb:17:in `start!' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-dns-1.1.0/lib/vagrant-dns/service.rb:52:in `restart!' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-dns-1.1.0/lib/vagrant-dns/restart_middleware.rb:14:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:95:in `block in finalize_action' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:95:in `block in finalize_action' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:95:in `block in finalize_action' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/plugins/providers/virtualbox/action/check_guest_additions.rb:49:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-vbguest-0.13.0/lib/vagrant-vbguest/middleware.rb:31:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/Users/hi/.vagrant.d/gems/2.2.5/gems/vagrant-proxyconf-1.5.2/lib/vagrant-proxyconf/action/only_once.rb:33:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/plugins/providers/virtualbox/action/customize.rb:40:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/builtin/wait_for_communicator.rb:71:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/lib/vagrant/action/warden.rb:34:in `call' 
    from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-1.9.2/plugins/providers/virtualbox/action/customize.rb:40:in `call' 

我試圖找到從GitHub問題的一些解決方案: https://github.com/vagrant-landrush/landrush/issues/16

不知道。

還試圖安裝此:

gem install win32-process 

相同的結果。

所以我不知道真正的問題。

+2

我有點困惑,您是否試圖從Windows運行此代碼?因爲我非常確定'fork'在windows上不起作用,這就是爲什麼你會得到這個錯誤。 – Thermatix

+0

@Thermatix那麼流浪者在Windows上無法正常工作? –

+1

不,它應該沒問題,因爲我以前在Windows上使用它,您可能需要對其進行不同的配置。 – Thermatix

回答

0

據報道,vagrant-dns插件可能會在Windows上引發此問題。如果已安裝,請嘗試卸載它。

如果這不是一個選項,Windows 10具有您可以安裝的Linux Windows子系統功能。這將允許您利用Windows存儲中的一個Unix Distro應用程序來安裝bash shell。這將允許您在Linux環境中運行您的應用程序,從而有效地啓用Fork()