I can't execute command modprobe vboxdrv
I got into same problem
Solved it by disabling secure boot option.
Go to BIOS configuration and disable secure boot.
Sign virtual box modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) Centos 8
After some research, I found the solution.
Solution 1 : disable secure boot.
Solution 2 :
1- Install mokutil
package
sudo dnf update
sudo dnf install mokutil
2- Create RSA key under new folder.
sudo -i
mkdir /root/signed-modules
cd /root/signed-modules
openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MOK.der -nodes -days 36500 -subj "/CN=VirtualBox/"
chmod 600 MOK.priv
3- This command will ask you to add a password, you need this password after the next reboot.
sudo mokutil --import MOK.der
4- Reboot your system and a blue screen appear, select Enroll MOK --> Continue --> put the previous password and your system will start.
5- Put the previous cmmands in a script to run it later (after system update)
cd /root/signed-modules
vi sign-virtual-box
Add the following cmd to this script :
#!/bin/bash
for modfile in $(dirname $(modinfo -n vboxdrv))/*.ko; do
echo "Signing $modfile"
/usr/src/kernels/$(uname -r)/scripts/sign-file sha256 \
/root/signed-modules/MOK.priv \
/root/signed-modules/MOK.der "$modfile"
done
Use the below to find signfile if the above fails & edit script accordingly.
find /usr/src -name sign-file
5- Add exec permission and run the script
chmod 700 sign-virtual-box
./sign-virtual-box
6- Launch VirtualBOx
modprobe vboxdrv
For more info see this link (for ubuntu users)
https://stegard.net/2016/10/virtualbox-secure-boot-ubuntu-fail/
Failed to update Virtualbox on ubuntu 15.10
Check if Secure Boot is Enabled in your BIOS. If so, disable it. These are for 16.04 (it worked for me in 14.04):
https://askubuntu.com/questions/762136/cannot-reinstall-virtualbox-on-ubuntu-16-04
https://unix.stackexchange.com/questions/282265/starting-virtualbox-kernel-modules-failed
Related Topics
How to Make Awk Use the Variable Created in Bash Script
How to Make Perl Wait for Child Processes Started in the Background with System()
Linux Join Utility Complains About Input File Not Being Sorted
How to Create a Hex Dump of File Containing Only the Hex Characters Without Spaces in Bash
How to Tie a Network Connection to a Pid Without Using Lsof or Netstat
How to Use .Notparallel in Makefile Only on Specific Targets
Delete Whitespace in Each Begin of Line of File, Using Bash
Configuring Selinux Permissions on (Svs-V) Ipc Semaphores
Linux Command to Replace String in Large File with Another String
Shell Script Function Return a String
How to Recursively Search for Files with Certain Extensions
Using Sed to Get the Last N Lines of a Huge Text File
What Does the Gcc Error Message, "Error: Unsupported for 'Mov'", Mean
How to Detect Usb Device Disconnect Under Linux/Qt/C++
Setting Up a Workspace Using Team Explorer Everywhere on Linux