LoginSignup
4
4

More than 5 years have passed since last update.

カーネルアップデート後にVirtualBoxの共有フォルダが機能しなくなった場合の対処方法

Last updated at Posted at 2016-01-28

Vagrantなどで下手にカーネルをアップデートすると,共有フォルダが機能しなくなるのでその場合の対処方法.

Cent OS 6の場合

以下のコマンドをゲスト内で実行してカーネルモジュールを再コンパイルします.

sudo /etc/init.d/vboxadd setup

その後,再起動します.

Cent OS 7の場合

バージョンは適宜書き換えてください.もし,ここにvboxaddが無い場合は,/etc/systemd/system/multi-user.target.wants/vboxadd.serviceをみるとExecStart=の後ろに書いてあるはずです.

sudo /opt/VBoxGuestAdditions-5.0.12/init/vboxadd setup

自動的に再コンパイルを実行する

そもそもカーネルアップデートの度に再コンパイルするのは面倒なので,DKMSを用いて自動化します.DKMSはEPELリポジトリに入っているので,こちらを有効化してからインストールします.

sudo yum install epel-release
sudo yum install dkms
4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4