After killing the hung apt process I ran dpkg --configure -a , which hung again. Killing the hung dpkg process and running dpkg --configure -a again allowed the package installation to complete but resulted in a broken module:
$ VirtualBox
WARNING: The character device /dev/vboxdrv does not exist.
Please install the virtualbox-dkms package and the appropriate
headers, most likely linux-headers-generic.
You will not be able to start VMs until this problem is fixed.
$
After killing the hung apt process I ran dpkg --configure -a , which hung again. Killing the hung dpkg process and running dpkg --configure -a again allowed the package installation to complete but resulted in a broken module:
$ VirtualBox generic.
WARNING: The character device /dev/vboxdrv does not exist.
Please install the virtualbox-dkms package and the appropriate
headers, most likely linux-headers-
You will not be able to start VMs until this problem is fixed.
$