Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

**Disclaimer, I'm fairly new to Linux ~2 years at home and, mostly, have only used ubuntu.

I have salix (14.0) installed as host and would like to setup a debian(Squeeze) guest. In the process of installing Virtualbox on the host, it turned out I needed to compile the linux headers. In the process of that I needed to download the source from salix's repostory as it doesn't come with the iso, I noticed this was downloaded to /usr/src/.

The debian vm is up and I can interact within it fine but I've been unable to network it to the salix host (I've tried bridged and some other options after looking for more info online). Its resolution is also much smaller than I would expect having edited its xml config file. These issues make me suspect that the guest additions are not installed, trying to install them gives me no feedback (probably something in /var/logs but I can't check atm). I noticed that it does not contain the source code in /usr/src

    Do I need to compile debian source on the guest? Would I actually need the linux source instead, I'm a little confused on that point?

    How do I get the source to the guest (can't mount folders on guest without additions or ssh into it without internet to install ssh server)

    Where would I download the debian source from, I can't find it on the website, and don't have another debian instance to run aptitude install linux-source-3.2

Really it seems like I'm overcomplicating this and perhaps missed some simple step. Is there a good guide for setting up Virtualbox or similar managers with non-ubuntu guests? Information on this seems to get sparse quickly.

share|improve this question
add comment

2 Answers

up vote 3 down vote accepted

Debian backports provides a package virtualbox-guest-dkms which could be an easy solution to your problem:


If you install this package, then Debian should handle the dependency on the kernel headers automatically, and if it doesn't work, it should at least display a proper error message. To install it, you have to add the backports APT repository to your system, as explained in the documentation:


Then you should be able to install the package with the following command:

aptitude -t squeeze-backports install virtualbox-guest-dkms

Detailed answers to your questions:

In the process of installing Virtualbox on the host, it turned out I needed to compile the linux headers.

This is not technically correct. You don't need to compile the kernel headers themselves, but you need to compile the VirtualBox kernel modules, and this require the kernel headers. Installing the package virtualbox-guest-dkms should pull in the kernel headers as a dependency and then automatically compile and install the kernel modules with DKMS.

I've been unable to network it to the salix host (I've tried bridged and some other options after looking for more info online).

Oh well, this is a problem. But the network probably should work without the guest additions, so you should look into that first. Check on the guest if it detected the network card:

ifconfig -a
lspci -nn

ifconfig should show a eth* interface, and lspci should show an Ethernet controller.

The network type that you can configure in VirtualBox depends on your requirements:

  • Use "bridged" if you want your guest to have its own IP in your network, as if it were a real computer that is connected to your network switch. Then manually assign your guest a free IP in your network, or use a DHCP client to get an IP assigned from your DHCP server (which does of course require a DHCP server in your network).
  • Use "NAT" if you want your guest to be able to connect to computers in your LAN and to the Internet, but if you don't want the guest to appear as its own computer in your LAN. Then configure the guest to use DHCP, because VirtualBox will assign it a IP with its internal DHCP server.
  • Read the documentation for details and the remaining network modes that I'm too lazy to explain.

When you've got the network running, you should be able to proceed as I originally described.

share|improve this answer
Thanks, I'll have to give that a try this evening (maybe I'll be able to setup some static ips and scp it from the host) –  user1854496 Sep 17 '13 at 21:14
Ideally, the version of guest additions should match the version of VirtualBox running on the host. –  200_success Sep 17 '13 at 21:31
@200_success: right, but on the other hand I'd prefer a proper Debian package on my guest to some script that distributes its files all over my root filesystem everyday ;) –  Martin von Wittich Sep 17 '13 at 21:34
add comment

If you aren't insisting on using Virtualbox (which if I understand your question correctly you are not), you might want to give QEMU a try. (Not just) Slackware related documentation is for example at Eric Hameleer's site.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.