Virtualbox - vboxdrv error

If you have any suggestions or ideas about improving Salix, here's the place to post them.
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 22. May 2023, 08:05 What do you mean you "installed more kernel packages"?

All you need to do is install the kernel-source package. Make sure it is the same version as the kernel you are actually running.

Go to this page: https://www.virtualbox.org/wiki/Linux_Downloads
Get the file from the "All distributions" link.
Run it with:

Code: Select all

sh ./VirtualBox-...
Okay, it's me again. The problem is not solved, but I will try to describe what I did as clearly as possible.

"sudo slapt-get -u"

"sudo slapt-src -u"

"sudo slapt-get -i kernel-source (+ kernel-headers")

lilo -v

Error, "/boot/boot.0300 exists - no boot sector backup copy made."

reboot

"wget https://all_linux_distro_link" to a folder. Run "sh virtualblabla" and the program will install.

It complains about a bug, no kernel header. I have no idea if this is a common problem or just me being so unlucky, but the fact is that I haven't found a solution yet and it's holding me back from doing anything on Salix.
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Virtualbox - vboxdrv error

Post by gapan »

From a terminal, run:

Code: Select all

virtualbox
What do you get?

Also what does this show?

Code: Select all

ls -l /var/log/packages/kernel-*
Image
Image
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 25. May 2023, 17:41 From a terminal, run:

Code: Select all

virtualbox
What do you get?

Also what does this show?

Code: Select all

ls -l /var/log/packages/kernel-*
Through running:

Code: Select all

"<username>: virtualbox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
         available for the current kernel (5.15.63) or it failed to
         load. Please recompile the kernel module and install it by

           sudo /sbin/vboxconfig

         You will not be able to start VMs until this problem is fixed."

It is running, but showing this message.

After running the '/sbin/vboxconfig'

<username>: "sudo /sbin/vboxconfig

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.
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.

There were problems setting up VirtualBox.  To re-start the set-up process, run
  /sbin/vboxconfig
as root.  If your system is using EFI Secure Boot you may need to sign the
kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) before you can load
them. Please see your Linux system's documentation for more information."
After:

Code: Select all

<username>[~]$ "ls -l /var/log/packages/kernel-*
-rw-r--r-- 1 root root  106578 May 27 14:02 /var/log/packages/kernel-firmware-20220124_eb8ea1b-noarch-1
-rw-r--r-- 1 root root   30942 May 27 14:03 /var/log/packages/kernel-headers-5.15.63-x86-1
-rw-r--r-- 1 root root    1005 May 27 14:07 /var/log/packages/kernel-huge-5.15.63-x86_64-1
-rw-r--r-- 1 root root  330328 May 27 14:07 /var/log/packages/kernel-modules-5.15.63-x86_64-1
-rw-r--r-- 1 root root 5001664 May 28 14:32 /var/log/packages/kernel-source-5.15.94-noarch-1"
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 25. May 2023, 17:41 From a terminal, run:

Code: Select all

virtualbox
What do you get?

Also what does this show?

Code: Select all

ls -l /var/log/packages/kernel-*
Maybe this is a problem what I did bad with lilo?

After running "lilo":

Code: Select all

<username>[~]$ sudo lilo -v
LILO version 24.2 (released 22-November-2015)
  * Copyright (C) 1992-1998 Werner Almesberger  (until v20)
  * Copyright (C) 1999-2007 John Coffman  (until v22)
  * Copyright (C) 2009-2015 Joachim Wiedorn  (since v23)
This program comes with ABSOLUTELY NO WARRANTY. This is free software 
distributed under the BSD License (3-clause). Details can be found in 
the file COPYING, which is distributed with this software.

Warning: LBA32 addressing assumed
Reading boot sector from /dev/sda
Using BITMAP secondary loader
Calling map_insert_data
Mapping bitmap file /boot/salix.bmp
Calling map_insert_file

Boot image: /boot/vmlinuz -> vmlinuz-huge-5.15.63
Mapping RAM disk /boot/initrd.gz
The initial RAM disk will be loaded in the high memory above 16M.
Added Salix  +  *

Writing boot sector.
/boot/boot.0800 exists - no boot sector backup copy made.
One warning was issued.
I think I did something bad in the installation, or I missed an important things. Who knows.
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Virtualbox - vboxdrv error

Post by gapan »

Please post any terminal output within code tags. You do it like this:
[code]
your code here
[/code]

I have edited your previous posts and have added them for you, but please do so next time. It is very hard to read the output if you just paste it like that.

Anyway, it is easy to see what the problem is and you have already been provided the solution but you ignored it. I'm quoting my previous comment:
All you need to do is install the kernel-source package. Make sure it is the same version as the kernel you are actually running.
Read it again until you understand what it says. Then examine the output of what you posted for the

Code: Select all

ls -l /var/log/packages/kernel-*
command. If you can't find the problem, read it again. More carefully this time.

By the way, there is nothing wrong with your LILO output. Again, don't just skim over the output. Sit down and actually read it. A warning is not an error. It's just that, a warning.
Image
Image
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 29. May 2023, 21:01 Please post any terminal output within code tags. You do it like this:
[code]
your code here
[/code]

I have edited your previous posts and have added them for you, but please do so next time. It is very hard to read the output if you just paste it like that.

Anyway, it is easy to see what the problem is and you have already been provided the solution but you ignored it. I'm quoting my previous comment:
All you need to do is install the kernel-source package. Make sure it is the same version as the kernel you are actually running.
Read it again until you understand what it says. Then examine the output of what you posted for the

Code: Select all

ls -l /var/log/packages/kernel-*
command. If you can't find the problem, read it again. More carefully this time.

By the way, there is nothing wrong with your LILO output. Again, don't just skim over the output. Sit down and actually read it. A warning is not an error. It's just that, a warning.
I was actually hoping you would help me with this, and then I understood. I am very new to the Linux Kernel. I have run countless Linux Distros, but never had a problem with the kernel. It is time for me to change that.The last line doesn't match the kernel version, but the current kernel-source [slapt-get -i kernel-source-$(uname -r)] does nothing. As soon as I reinstalled kernel-header, kernel-modules, kernel-firmware, and rebooted the system, it did nothing. No mouse, no keyboard.I can't really find fault with it, because as I said, I'm new to the Linux Kernel world. Salix introduced me to this world, but it's not that easy. If I could get VirtualBox to run properly on my system, that in itself would be a miracle.

But I try, but always without success.
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 29. May 2023, 21:01 Please post any terminal output within code tags. You do it like this:
[code]
your code here
[/code]

I have edited your previous posts and have added them for you, but please do so next time. It is very hard to read the output if you just paste it like that.

Anyway, it is easy to see what the problem is and you have already been provided the solution but you ignored it. I'm quoting my previous comment:
All you need to do is install the kernel-source package. Make sure it is the same version as the kernel you are actually running.
Read it again until you understand what it says. Then examine the output of what you posted for the

Code: Select all

ls -l /var/log/packages/kernel-*
command. If you can't find the problem, read it again. More carefully this time.

By the way, there is nothing wrong with your LILO output. Again, don't just skim over the output. Sit down and actually read it. A warning is not an error. It's just that, a warning.
Anyway, I did this:

Code: Select all

sudo slapt-get -i kernel-huge kernel-modules kernel-headers kernel-firmware kernel-source
Then "lilo -v" [also /boot error], then reboot, and everything loaded until the encrypted disk was unlocked, then Salix booted but did not detect the mouse or keyboard. But you know what? I'm not giving up even if I have to, I try to understand the whole Linux kernel and all the crap that goes with it inside and out. :D
User avatar
gapan
Salix Wizard
Posts: 6238
Joined: 6. Jun 2009, 17:40

Re: Virtualbox - vboxdrv error

Post by gapan »

Good! You found out how to upgrade the kernel and than you had to run lilo after you've done that!

But you didn't mention anything about an encrypted disk before! You'll have to follow the same process for creating an initrd just as you did the first time.
Image
Image
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 30. May 2023, 19:12 Good! You found out how to upgrade the kernel and than you had to run lilo after you've done that!

But you didn't mention anything about an encrypted disk before! You'll have to follow the same process for creating an initrd just as you did the first time.
Working. I ran the above command, which includes kernel-modules, kernel-headers, etc. VirtualBox now works properly.

The problem was that after installing the kernel packages, I skipped the "mkinitrd" command, which I typed in after the installer [I didn't think to I need to type it again]. I then typed in the "lilo" command and it gave no error or warning. I rebooted the system and VirtualBox works perfectly correctly without the slightest error.
lurker666
Posts: 32
Joined: 24. Apr 2023, 09:42

Re: Virtualbox - vboxdrv error

Post by lurker666 »

gapan wrote: 30. May 2023, 19:12 Good! You found out how to upgrade the kernel and than you had to run lilo after you've done that!

But you didn't mention anything about an encrypted disk before! You'll have to follow the same process for creating an initrd just as you did the first time.
If you hadn't mentioned the word "mkinitrd", it would have completely slipped my mind and I would have forgotten it every time. :D
Post Reply