Install question about kernels

Discussions related to using the OSE version of VirtualBox.
Post Reply
azdour
Posts: 7
Joined: 22. Jul 2009, 13:28
Primary OS: Ubuntu 8.04
VBox Version: OSE Debian
Guest OSses: Windows XP

Install question about kernels

Post by azdour »

Hi,

I recently installed VirtualBox OSE and chose the wrong generic kernel. Do I need to remove the wrong generic kernel before installing the correct one? Or does VirtualBox intelligently detect which kernel I'm running under and load the correct module?

Thanks in advance.

Regards,

Tim.
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: Install question about kernels

Post by TerryE »

Both the VBox host drivers and the VBox Guest Additions must be linked against the correct kernel to work in both the host and guest OSs respectively. However given that the kernels are routinely upgraded, both include scripts to rebuild the necessary modules. In the case of the host, this is the /etc/init.d/vboxdrv setup command. Remember that you need the correct Linux kernel headers and the essential build tools installed for this to work.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
fixedwheel
Volunteer
Posts: 1699
Joined: 13. Sep 2008, 02:18

Re: Install question about kernels

Post by fixedwheel »

TerryE wrote:In the case of the host, this is the /etc/init.d/vboxdrv setup command.
Terry, the question is in Virtualbox OSE, the OP wrote OSE ... but vboxdrv setup is for the PUEL

@azdour install the kernel(s) you want but make sure you install the matching virtualbox-ose-modules package(s)
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: Install question about kernels

Post by TerryE »

Sorry my mistake. Doesn't the Debian OSE still have a vboxdrv module ?? It's certainly in src/VBox/Installer/linux/vboxdrv.sh.in in the OSE distro.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
fixedwheel
Volunteer
Posts: 1699
Joined: 13. Sep 2008, 02:18

Re: Install question about kernels

Post by fixedwheel »

Debian OSE still have a vboxdrv module ??
yes probably in the virtualbox-ose-modules packages ;)
azdour
Posts: 7
Joined: 22. Jul 2009, 13:28
Primary OS: Ubuntu 8.04
VBox Version: OSE Debian
Guest OSses: Windows XP

Re: Install question about kernels

Post by azdour »

Hi,

Thanks for the replies. Although I still confused :) I've installed two kernels via the Ubuntu Synaptec Package Manager. Will VirtualBox know about both kernels and load the correct one - or should I only have one kernel?

I know it may all sound strange :) but I have a DRBL Server that runs on a different kernel to the clients that boot off it. The clients can run the software from the Server on their own hardware. I've installed the 386 kernel for the Server so that I can test it on the Server and it seems to work. I've also installed at the same time the kernel for the client. I have a sneaky feeling that VirtualBox is only seeing one of ther kernels - the kernel for the Server, which is why when the Client machine runs VirtualBox you get the 'kernel module' not found/loaded (or something similar).

Any further help would be greatly appreciated.
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: PUEL
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: Install question about kernels

Post by Sasquatch »

VB can use multiple kernels without issues, but you have to install the module on it before it works. You do this by compiling the module. Normally, DKMS takes care of this, but it can be manually ran if you use "/etc/init.d/vboxdrv setup", which the OSE version should have by now.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
azdour
Posts: 7
Joined: 22. Jul 2009, 13:28
Primary OS: Ubuntu 8.04
VBox Version: OSE Debian
Guest OSses: Windows XP

Re: Install question about kernels

Post by azdour »

Hi,

Thanks for the quick reply. Having done uname -a on both Server and Client I'm sure I've installed both 386 kernels so I'll keep on investigating why the Client says it may be missing.
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: PUEL
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: Install question about kernels

Post by Sasquatch »

You mean about the VB kernel module? That's pretty obvious, it's not build on and for the kernel where you want to start it on. Rebuilding the module will certainly solve that.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
TerryE
Volunteer
Posts: 3572
Joined: 28. May 2008, 08:40
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu 10.04 & 11.10, both Svr&Wstn, Debian, CentOS
Contact:

Re: Install question about kernels

Post by TerryE »

azdour wrote:still confused :) I've installed two kernels via the Ubuntu Synaptec Package Manager. Will VirtualBox know about both kernels and load the correct one - or should I only have one kernel? ... I have a DRBL Server that runs on a different kernel to the clients that boot off it. The clients can run the software from the Server on their own hardware. I've installed the 386 kernel for the Server so that I can test it on the Server and it seems to work. I've also installed at the same time the kernel for the client. I have a sneaky feeling that VirtualBox is only seeing one of the kernels - the kernel for the Server, which is why when the Client machine runs VirtualBox you get the 'kernel module' not found/loaded (or something similar).
You need to go back to VM an Linux basics
  1. The guest is a VM that is a different machine albeit virtual from the perspective of the OS that runs on it. The Host OS doesn't know or care about the guest OS and v.v.
  2. You need to install virtualbox-ose module on the host and virtualbox-ose-guest on the guest
  3. Whilst you can install multiple kernels on a Linux system, you will only boot one of these.
  4. For virtualbox to work, it must be linked against the kernel that you've booted. You find this by the uname -r command. You can either do this by running the setup command as discussed about or picking the explicit version from Synaptec. So the umbrella package virtualbox-ose-modules-generic will in fact install the version for the latest generic kernel (which is what you use on a workstation). If you are booting a different version, say 2.6.24-23-generic then you need to install virtualbox-ose-modules-2.6.24-23-generic, etc.
  5. If you kernel is upgraded by the update process then you need to load the new module for that kernel or relink the old one using setup.
  6. If you boot with the alternate kernel then VBox won't work.
Read the Forum Posting Guide
Google your Q site:VirtualBox.org or search for the answer before posting.
azdour
Posts: 7
Joined: 22. Jul 2009, 13:28
Primary OS: Ubuntu 8.04
VBox Version: OSE Debian
Guest OSses: Windows XP

Re: Install question about kernels

Post by azdour »

Hi Terry,

Thanks, your explanation has helped me understand more about VirtualBox and how it works. I'm going to try and get my server/client using the same kernel. VBox seems to work on the Server so I know the correct kernels are there, its just a case of updating the client to the same kernel.
Post Reply