Debian 9を実行しているデスクトップにvirtualboxをインストールし、仮想マシンファイルをダウンロードしてvirtualboxにインポートしました。問題は、仮想マシンを起動しようとすると、端末で「/sbin/vboxconfig」を実行するように求められます。だからそうすると、次のような結果が出ます。
root@MaxPC:/home/maxwell# /sbin/vboxconfig
Created symlink /etc/systemd/system/multi-user.target.wants/vboxdrv.service → /lib/systemd/system/vboxdrv.service.
Created symlink /etc/systemd/system/multi-user.target.wants/vboxballoonctrl-service.service → /lib/systemd/system/vboxballoonctrl-service.service.
Created symlink /etc/systemd/system/multi-user.target.wants/vboxautostart-service.service → /lib/systemd/system/vboxautostart-service.service.
Created symlink /etc/systemd/system/multi-user.target.wants/vboxweb-service.service → /lib/systemd/system/vboxweb-service.service.
vboxdrv.sh: Stopping VirtualBox services.
vboxdrv.sh: Starting VirtualBox services.
vboxdrv.sh: Building VirtualBox kernel modules.
This system is currently not set up to build kernel modules.
Please install the Linux kernel "header" files matching the current kernel
for adding new hardware support to the system.
The distribution packages containing the headers are probably:
linux-headers-amd64 linux-headers-4.18.0-0.bpo.1-amd64
This system is currently not set up to build kernel modules.
Please install the Linux kernel "header" files matching the current kernel
for adding new hardware support to the system.
The distribution packages containing the headers are probably:
linux-headers-amd64 linux-headers-4.18.0-0.bpo.1-amd64
There were problems setting up VirtualBox. To re-start the set-up process, run
/sbin/vboxconfig
as root.
その後、「sudo apt-get install linux-headers-4.18.0-0.bpo.1-amd64」を実行して問題が解決するかどうかを確認しましたが、次のような結果が得られました.
root@MaxPC:/home/maxwell# sudo apt-get install linux-headers-4.18.0-0.bpo.1-amd64
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
linux-headers-4.18.0-0.bpo.1-amd64 : Depends: linux-compiler-gcc-6-x86 (>= 4.14.17-1~) but 4.9.130-2 is to be installed
E: Unable to correct problems, you have held broken packages.
仮想マシンを起動するにはどうすればよいですか?
答え1
で述べたようにこのバグレポートターゲットバージョンを指定する必要があります。努力する:
sudo apt-get install -t stretch-backports linux-headers-4.18.0-0.bpo.1-amd64