質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Vagrant

Vagrantは、VirtualBox上の仮想マシンを コマンドラインから作成してくれるソフトウェアです。 ビルド環境など容易に構築が可能です。

Q&A

解決済

1回答

5818閲覧

vagrant up時にエラーが発生する

suguru_nansai

総合スコア35

Vagrant

Vagrantは、VirtualBox上の仮想マシンを コマンドラインから作成してくれるソフトウェアです。 ビルド環境など容易に構築が可能です。

0グッド

0クリップ

投稿2016/07/03 11:06

表題に記載の通り、vagrant up時にエラーが発生してしまいます。
エラーメッセージを記載いたしますので、原因等お分かりになりましたらご教示ください。
よろしくお願い申し上げます。

エラーメッセージ

Last login: Sun Jul 3 12:31:06 on ttys000
suguru:~ NANSAI-SUGURU$ vagrant plugin install vagrant-vbguest
/opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr in PATH, mode 040777
/opt/vagrant/embedded/gems/gems/bundler-1.10.6/lib/bundler/shared_helpers.rb:78: warning: Insecure world writable dir /usr in PATH, mode 040777
Installing the 'vagrant-vbguest' plugin. This can take a few minutes...
Installed the plugin 'vagrant-vbguest (0.12.0)'!
suguru:~ NANSAI-SUGURU$ vagrant box add ubuntu15 https://github.com/kraksoft/vagrant-box-ubuntu/releases/download/15.04/ubuntu-15.04-amd64.box
/opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr in PATH, mode 040777
/opt/vagrant/embedded/gems/gems/bundler-1.10.6/lib/bundler/shared_helpers.rb:78: warning: Insecure world writable dir /usr in PATH, mode 040777
==> box: Box file was not detected as metadata. Adding it directly...
==> box: Adding box 'ubuntu15' (v0) for provider:
box: Downloading: https://github.com/kraksoft/vagrant-box-ubuntu/releases/download/15.04/ubuntu-15.04-amd64.box
==> box: Successfully added box 'ubuntu15' (v0) for 'virtualbox'!
suguru:~ NANSAI-SUGURU$ cd Desktop
suguru:Desktop NANSAI-SUGURU$ mkdir work
suguru:Desktop NANSAI-SUGURU$ cd work
suguru:work NANSAI-SUGURU$ mkdir vagrant
suguru:work NANSAI-SUGURU$ cd vagrant
suguru:vagrant NANSAI-SUGURU$ vagrant init ubuntu15
/opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr in PATH, mode 040777
/opt/vagrant/embedded/gems/gems/bundler-1.10.6/lib/bundler/shared_helpers.rb:78: warning: Insecure world writable dir /usr in PATH, mode 040777
A Vagrantfile has been placed in this directory. You are now
ready to vagrant up your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
vagrantup.com for more information on using Vagrant.
suguru:vagrant NANSAI-SUGURU$ vagrant up
/opt/vagrant/embedded/gems/gems/vagrant-1.8.1/lib/vagrant/pre-rubygems.rb:31: warning: Insecure world writable dir /usr in PATH, mode 040777
/opt/vagrant/embedded/gems/gems/bundler-1.10.6/lib/bundler/shared_helpers.rb:78: warning: Insecure world writable dir /usr in PATH, mode 040777
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'ubuntu15'...
==> default: Matching MAC address for NAT networking...
==> default: Setting the name of the VM: vagrant_default_1467543356279_99403
==> 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: 3000 (guest) => 3000 (host) (adapter 1)
default: 22 (guest) => 2222 (host) (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:
default: Vagrant insecure key detected. Vagrant will automatically replace
default: this with a newly generated keypair for better security.
default:
default: Inserting generated public key within guest...
default: Removing insecure key from the guest if it's present...
default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
[default] GuestAdditions versions on your host (5.0.10) and guest (4.3.22_Ubuntu r98236) do not match.
stdin: is not a tty
Reading package lists...
Building dependency tree...
Reading state information...
linux-headers-3.19.0-15-generic is already the newest version.
linux-headers-3.19.0-15-generic set to manually installed.
The following NEW packages will be installed:
dkms
0 upgraded, 1 newly installed, 0 to remove and 41 not upgraded.
Need to get 65.5 kB of archives.
After this operation, 351 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu/ vivid/main dkms all 2.2.0.3-2ubuntu3 [65.5 kB]
dpkg-preconfigure: unable to re-open stdin: No such file or directory
Fetched 65.5 kB in 3s (20.6 kB/s)
Selecting previously unselected package dkms.
(Reading database ... 60906 files and directories currently installed.)
Preparing to unpack .../dkms_2.2.0.3-2ubuntu3_all.deb ...
Unpacking dkms (2.2.0.3-2ubuntu3) ...
Processing triggers for man-db (2.7.0.2-5) ...
Setting up dkms (2.2.0.3-2ubuntu3) ...
Copy iso file /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso into the box /tmp/VBoxGuestAdditions.iso
stdin: is not a tty
mount: /dev/loop0 is write-protected, mounting read-only
Installing Virtualbox Guest Additions 5.0.10 - guest version is 4.3.22_Ubuntu r98236
stdin: is not a tty
Verifying archive integrity... All good.
Uncompressing VirtualBox 5.0.10 Guest Additions for Linux............
VirtualBox Guest Additions installer
Copying additional installer modules ...
Installing additional modules ...
Removing existing VirtualBox DKMS kernel modules ...done.
Removing existing VirtualBox non-DKMS kernel modules ...done.
Building the VirtualBox Guest Additions kernel modules ...done.
Doing non-kernel setup of the Guest Additions ...done.
You should restart your guest to make sure the new modules are actually used

Installing the Window System drivers
Could not find the X.Org or XFree86 Window System, skipping.
An error occurred during installation of VirtualBox Guest Additions 5.0.10. Some functionality may not work as intended.
In most cases it is OK that the "Window System drivers" installation failed.
stdin: is not a tty
vagrant_vbguest.machine_loop_guard
==> default: Checking for guest additions in VM...
==> default: Configuring and enabling network interfaces...
==> default: Mounting shared folders...
default: /vagrant => /Users/NANSAI-SUGURU/Desktop/work/vagrant
Failed to mount folders in Linux guest. This is usually because
the "vboxsf" file system is not available. Please verify that
the guest additions are properly installed in the guest and
can work properly. The command attempted was:

mount -t vboxsf -o uid=id -u vagrant,gid=getent group vagrant | cut -d: -f3 vagrant /vagrant
mount -t vboxsf -o uid=id -u vagrant,gid=id -g vagrant vagrant /vagrant

The error output from the last command was:

stdin: is not a tty
/sbin/mount.vboxsf: mounting failed with the error: No such device

suguru:vagrant NANSAI-SUGURU$

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

ベストアンサー

ゲストマシンのパッケージマネージャーをアップデートすると,vbox guest additionとモジュールの不整合が起こり,そのようなエラーが起きることがあります。
yumなどをアップデートした際,その都度vbox guest additionをリビルドする必要があります。
ゲストマシン側で

bash

1sudo /etc/init.d/vboxadd setup

を実行してvagrant reloadを行ってみてください。
大体の場合それで直るはずですが,直らなかった場合は,別途また,作業が必要になるので
ご返答していただければと思います。

投稿2016/07/03 14:40

退会済みユーザー

退会済みユーザー

総合スコア0

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

suguru_nansai

2016/07/04 14:23

ご回答ありがとうございます。 ご連携いただいたコマンドを入力いたしましたが、下記の通りのメッセージになってしまいます。 suguru:vagrant NANSAI-SUGURU$ sudo /etc/init.d/vboxadd setup sudo: /etc/init.d/vboxadd: command not found ご指導よろしくお願い申し上げます。
退会済みユーザー

退会済みユーザー

2016/07/04 14:55

インストールしたboxが悪かったんでしょうね。 初期起動であれば他のboxをインストールした方が早いかもしれません。 一応この記事の手順を追ってもらえれば直ると思います。 http://zow.hatenablog.com/entry/20150116/1421336024
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問