vagrant-vbguest インストール
vagrant up で 下記の警告が出て対処したのでメモ。
The guest additions on this VM do not match the installed version of VirtualBox! In most cases this is fine, but in rare cases it can cause things such as shared folders to not work properly. If you see shared folder errors, please make sure the guest additions within the virtual machine match the version of VirtualBox you have installed on your host and reload your VM.
VirtualBox本体とguest addition のバージョンがずれているということらしい。
ということでゲストのバージョンを上げてくれるプラグインをインストールします。
以下はVagrant のバージョンが 1.1以上の場合です。
インストールはこれ
$ vagrant plugin install vagrant-vbguest
デフォルトではvagrant up, vagrant reload 時に自動で更新されてしまうらしいので
それが嫌な場合は設定ファイルを作成します。
~/.vagrant.d/Vagrantfile を作成して中身を下記のように編集。
Vagrant.configure("2") do |config| config.vbguest.auto_update = false end
本体とゲストのバージョンが違うか調べるには下記コマンド。
$ vagrant vbguest --status
違いがあれば下記コマンドでゲストを最新にします。
$ vagrant vbguest --do install
最後にエラーがでるかもしれませんが、恐らく問題ありません。
あとは vagrant reload して反映して終了です。