首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >流浪者在配置中使b/c专用网络线路崩溃

流浪者在配置中使b/c专用网络线路崩溃
EN

Stack Overflow用户
提问于 2014-09-04 12:00:35
回答 2查看 1.4K关注 0票数 0

我无法在我的配置中为VM指定ip,这会使迷航崩溃。

现在我的Vagrantfile文件:

代码语言:javascript
复制
# -*- mode: ruby -*-
# vi: set ft=ruby :

Vagrant.configure(2) do |config|
    config.vm.box = "puphpet/centos65-x64"
    config.vm.network "private_network", ip: "192.168.33.10"
end

里面还有更多的东西,但我已经把它缩小到这个地步了。如果我运行vagrant up

代码语言:javascript
复制
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'puphpet/centos65-x64'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'puphpet/centos65-x64' is up to date...
==> default: Setting the name of the VM: website_default_1409831132235_3604
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
    default: Adapter 2: hostonly
==> default: Forwarding ports...
    default: 22 => 2222 (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection timeout. Retrying...
==> default: Machine booted and ready!
GuestAdditions versions on your host (4.3.14) and guest (4.3.10) do not match.
<snipped - guest additions installation>
==> default: Checking for guest additions in VM...
==> default: Configuring and enabling network interfaces...
==> default: Forcing shutdown of VM...
==> default: Destroying VM and associated drives...
/Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/plugins/guests/redhat/cap/configure_networks.rb:31:in `configure_networks_default': wrong number of arguments (1 for 2) (ArgumentError)
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/plugins/guests/redhat/cap/configure_networks.rb:19:in `configure_networks'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/lib/vagrant/capability_host.rb:111:in `call'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/lib/vagrant/capability_host.rb:111:in `capability'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/lib/vagrant/guest.rb:43:in `capability'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/plugins/providers/virtualbox/action/network.rb:132:in `call'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/lib/vagrant/action/warden.rb:34:in `call'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/plugins/providers/virtualbox/action/clear_network_interfaces.rb:26:in `call'
    from /Applications/Vagrant/embedded/gems/gems/vagrant-1.6.4/lib/vagrant/action/warden.rb:34:in `call'
    <snipped>

如果我禁用了专用网络线路,它可以工作,但我无法控制IP。

我已经测试了另一种写作方法(是的,我非常绝望):

代码语言:javascript
复制
 config.vm.network :private_network, :ip => "192.168.33.10"

尝试使用和不使用:net掩码参数(因为堆栈跟踪是关于参数的)

我的详细资料:

  • MacOS 10.9.4
  • Ruby2.1.2p95
  • 流浪者1.6.4
  • VirtualBox 4.3.14

我用几个不同的盒子(都是基于CentOS的)来测试这个问题,问题是所有的盒子都是一样的,在互联网上搜索我能想到的一切。

一切都没有结果。不知道怎么继续,请帮帮忙?

EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2014-09-04 12:24:21

我有同样的环境,我也遇到过这种情况。看起来这是一个已知的bug:github.com/mitchellh/vagrant/issues/4458

在修复此bug之前,我担心您唯一的选择是手动修补Vagrant中包含在问题报告中的详细信息,或者将其降级为Vagrant1.6.3。我已经降级到1.6.3,并可以确认,这是预期的工作。

票数 6
EN

Stack Overflow用户

发布于 2014-09-05 18:16:40

我在Vagrant1.6.4中也有相同的错误,它似乎是在Vagrant1.6.5中修正的。

票数 3
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/25664945

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档