このエントリーをはてなブックマークに追加


Debian 10 Buster にVirtualBox guest additionsをインストールする

Debian 10 BusterにVirtualBoxのGuest Additionsをインストールした時の備忘録です。

Debian 11 (bullseye)でも同様の操作でインストールできました。


動作環境

  • ホストOS
    Windows 10 ver.1909 64bit
  • ゲストOS
    $ lsb_release -d
    Description:    Debian GNU/Linux 10 (buster)

Guest Additonsのインストール手順

以下の手順でVirtualBoxのGuest Additionsをインストールしました。

Guest Additionsのインストールに必要と思われるパッケージをインストールします。

  1. rootにスイッチユーザ(su)します。
    su -
  2. 端末(ターミナル)を起動し、アップデートします。
    apt update && apt upgrade -y
  3. アップデートがあった場合、再起動します。(Debian VMの再起動)
    reboot
  4. パッケージをインストールします。
    apt install -y dkms build-essential module-assistant
  5. m-aコマンドの実行
    m-a prepare
  6. 端末(ターミナル)は下の操作で使いますので、閉じないでください。

Guest additonsのISOイメージのマウント

以下の手順で Guest additions のISOイメージをマウントします。

  1. メニューバーの「デバイス」をクリックします。
  2. 「Guest Additions CD イメージ挿入...」をクリックします。
    01.png
     
    マウントされているパスが /media/cdrom0 であることが確認できます。
    02.png
     
  3. /media/cdrom0 に cd します。
    cd /media/cdrom0/
  4. ls コマンドを実行すると以下のように Guest Additions のファイル群を確認できます。
    今回利用するのは、VBoxLinuxAdditions.runになります。
    root@debian:/media/cdrom0# ls -ltr
    合計 62774
    -r--r--r-- 1 root root      763  1月 22  2019 AUTORUN.INF
    -r--r--r-- 1 root root     3949 10月 11 03:44 VBoxDarwinAdditionsUninstall.tool
    -r--r--r-- 1 root root  3732506 10月 11 03:44 VBoxDarwinAdditions.pkg
    -r-xr-xr-x 1 root root     4821 10月 11 03:46 runasroot.sh
    -r-xr-xr-x 1 root root     6384 10月 11 03:46 autorun.sh
    -r--r--r-- 1 root root 16585216 10月 11 03:46 VBoxSolarisAdditions.pkg
    -r-xr-xr-x 1 root root  8611252 10月 11 03:46 VBoxLinuxAdditions.run
    -r-xr-xr-x 1 root root   270104 10月 11 03:46 VBoxWindowsAdditions.exe
    -r-xr-xr-x 1 root root 12135624 10月 11 03:48 VBoxWindowsAdditions-x86.exe
    -r-xr-xr-x 1 root root 22920216 10月 11 03:51 VBoxWindowsAdditions-amd64.exe
    dr-xr-xr-x 2 root root      792 10月 11 03:52 cert
    -r--r--r-- 1 root root      547 10月 11 03:52 TRANS.TBL
    dr-xr-xr-x 2 root root     2652 10月 11 03:52 OS2
    dr-xr-xr-x 2 root root     1824 10月 11 03:52 NT3x
  5. VBoxLinuxAdditions.runを実行します。
    bash ./VBoxLinuxAdditions.run
  6. 以下のようにメッセージが出力され、コンパイル&インストールが開始されます。
    root@debian:/media/cdrom0# bash ./VBoxLinuxAdditions.run
    Verifying archive integrity... All good.
    Uncompressing VirtualBox 6.0.14 Guest Additions for Linux........
    VirtualBox Guest Additions installer
    Copying additional installer modules ...
    Installing additional modules ...
    VirtualBox Guest Additions: Starting.
    VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel
    modules.  This may take a while.
    VirtualBox Guest Additions: To build modules for other installed kernels, run
    VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup <version>
    VirtualBox Guest Additions: or
    VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup all
    VirtualBox Guest Additions: Building the modules for kernel 4.19.0-6-amd64.
    update-initramfs: Generating /boot/initrd.img-4.19.0-6-amd64
    VirtualBox Guest Additions: Running kernel modules will not be replaced until
    the system is restarted
    root@debian:/media/cdrom0#
  7. Debianを再起動します。

以上の操作で、VirtualBox の Guest Additions のインストールは完了です。



添付ファイル: file02.png 618件 [詳細] file01.png 533件 [詳細]

トップ   編集 凍結 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2022-01-03 (月) 14:50:53