Vagrant: Opentable/win-2012r2-standard-amd64-nocm не работает с гостевыми дополнениями.

Я пытался заставить коробку opentable/win-2012r2-standard-amd64-nocm встать, чтобы возиться с шеф-поваром, но, к сожалению, это не работает.

Характеристики:

  • Виртуальная коробка v4.3.12
  • Бродяга v1.6.2
  • ОС Mac OSX v10.9.2

Способ 1: Попытка бродить по ящику opentable/win-2012r2-standard-amd64-nocm, чтобы просто возиться с Chef.
Проблема: похоже, он не хочет монтироваться бродячие папки, потому что ему не нравятся установленные в данный момент гостевые надстройки.

Alexs-MacBook-Pro:chef-repo alex$ vagrant up
WARNING: Could not load IOV methods. Check your GSSAPI C library for an update
WARNING: Could not load AEAD methods. Check your GSSAPI C library for an update
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'opentable/win-2012r2-standard-amd64-nocm'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'opentable/win-2012r2-standard-amd64-nocm' is up to date...
==> default: Setting the name of the VM: chef-repo_default_1401127106312_6161
==> default: Fixed port collision for 22 => 2222. Now on port 2200.
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 5985 => 5985 (adapter 1)
    default: 80 => 8080 (adapter 1)
    default: 3389 => 3389 (adapter 1)
    default: 22 => 2200 (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
    default: No guest additions were detected on the base box for this VM! Guest
    default: additions are required for forwarded ports, shared folders, host only
    default: networking, and more. If SSH fails on this machine, please install
    default: the guest additions and repackage the box to continue.
    default: 
    default: This is not an error message; everything may continue to work properly,
    default: in which case you may ignore this message.
==> default: Mounting shared folders...
    default: /vagrant => /Users/alex/Documents/Code/GitHubEnterprise/ConfigurationFiles/chef/chef-repo
==> default: Running provisioner: shell... 

Способ 2: Попытка переделать базовую коробку opentable/win-2012r2-standard-amd64-nocm с необходимой версией гостевых дополнений.
Проблема: Не удалось обнаружить гостевую операционную систему машины

Шаги:

  1. vagrant init opentable/win-2012r2-standard-amd64-nocm
  2. бродить вверх
  3. подождите, пока он загрузится в графическом режиме
  4. Выключите виртуальную машину
  5. Добавьте устройство CD/DVD и оставьте его пустым с помощью виртуального графического интерфейса.
  6. бродить вверх
  7. войдите в него через виртуальный ящик, установите гостевые дополнения, перезагрузите сервер.
  8. бродячая остановка
  9. Используйте виртуальный ящик для удаления гостевых дополнений cd/dvd.
  10. vagrant package --base {имя ящика в виртуальном ящике}
  11. ждать вечно
  12. vagrant box add package.box --name {имя ящика для добавления в провайдера
  13. ждать вечно
  14. Сделанный!!!

С этого момента я пытаюсь бродить по ящику, который я только что создал, и это дает мне эту ошибку:

Alex-MacBook-Pro:Alex_vs2012 Alex$ vagrant init Alex/win2012<br />
WARNING: Could not load IOV methods. Check your GSSAPI C library for an update<br />
WARNING: Could not load AEAD methods. Check your GSSAPI C library for an update<br />
A `Vagrantfile` has been placed in this directory. You are now<br />
ready to `vagrant up` your first virtual environment! Please read<br />
the comments in the Vagrantfile as well as documentation on<br />
`vagrantup.com` for more information on using Vagrant.<br />
Alex-MacBook-Pro:Alex_vs2012 alex$ vagrant up<br />
WARNING: Could not load IOV methods. Check your GSSAPI C library for an update<br />
WARNING: Could not load AEAD methods. Check your GSSAPI C library for an update<br />
Bringing machine 'default' up with 'virtualbox' provider...<br />
==> default: Importing base box 'Alex/win2012'...<br />
==> default: Matching MAC address for NAT networking...<br />
==> default: Setting the name of the VM: Alex_vs2012_default_1401126335265_42094<br />
==> default: Clearing any previously set network interfaces...<br />
==> default: Preparing network interfaces based on configuration...<br />
    default: Adapter 1: nat<br />
==> default: Forwarding ports...<br />
    default: 22 => 2222 (adapter 1)<br />
==> default: Booting VM...<br />
==> default: Waiting for machine to boot. This may take a few minutes...<br />
    default: SSH address: 127.0.0.1:2222<br />
    default: SSH username: vagrant<br />
    default: SSH auth method: private key<br />
    default: Warning: Connection timeout. Retrying...<br />
==> default: Machine booted and ready!<br />
==> default: Checking for guest additions in VM...<br />
    The guest operating system of the machine could not be detected!<br />
    Vagrant requires this knowledge to perform specific tasks such<br />
    as mounting shared folders and configuring networks. Please add<br />
    the ability to detect this guest operating system to Vagrant<br />
    by creating a plugin or reporting a bug.<br />

Кто-нибудь знает, что я делаю неправильно? Моя цель состояла в том, чтобы сделать так, чтобы папки монтировались во время операции vagrant up, чтобы я мог загрузить виртуальную машину с помощью файла bootstrap.sh и в конечном итоге возиться с шеф-поваром.

Вот мой Vagrantfile:

# -*- mode: ruby -*-
# vi: set ft=ruby :

# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"

Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# All Vagrant configuration is done here. The most common configuration
# options are documented and commented below. For a complete reference,
# please see the online documentation at vagrantup.com.

# Every Vagrant virtual environment requires a box to build off of.
config.vm.box = "opentable/win-2012r2-standard-amd64-nocm"
config.vm.provision :shell, :path => "bootstrap.sh"

# Create a forwarded port mapping which allows access to a specific port
# within the machine from a port on the host machine. In the example below,
# accessing "localhost:8080" will access port 80 on the guest machine.
config.vm.network "forwarded_port", guest: 80, host: 8080
config.vm.network "forwarded_port", guest: 3389, host: 3389

# Provider-specific configuration so you can fine-tune various
# backing providers for Vagrant. These expose provider-specific options.
# Example for VirtualBox:
#
config.vm.provider "virtualbox" do |vb|
#  # Don't boot with headless mode
vb.gui = true
#
#   # Use VBoxManage to customize the VM. For example to change memory:
#   vb.customize ["modifyvm", :id, "--memory", "1024"]
end
#
# View the documentation for the provider you're using for more
# information on available options.

# set auto_update to false, if you do NOT want to check the correct 
# additions version when booting this machine
config.vbguest.auto_update = false

# do NOT download the iso file from a webserver
config.vbguest.no_remote = true
end

person user1079703    schedule 26.05.2014    source источник


Ответы (2)


У меня также были проблемы с этим, но после того, как я обновил свою бродячую версию до последней (версия 1.7.2) и использовал конфигурацию Grim Wino Leader, я добился успеха.

Я следовал вашим инструкциям в способе 2, и после шага 1 я отредактировал Vagrantfile и добавил

config.vm.guest = :windows

Я использую:

  • Ubuntu 14.04.1 LTS (3.13.0-40 — универсальное ядро)
  • Vagrant 1.7.2 (скачивается с vagrantup.com)
  • виртуальный бокс-4.3 (4.3.20-96996~Ubuntu~разгон)
person stalet    schedule 11.02.2015

Не столько ответ, сколько обходной путь. Я тоже столкнулся с этой проблемой.

Можете добавить:

config.vm.guest = :windows

в ваш Vagrantfile. Обновлю это, если найду решение.

person Grim Wino Leader    schedule 29.05.2014