/ 3.2.6

BackTrack 5 R2 – VirtualBox Guest Additions + USB Issues Fixes

The famous Linux-based penetration testing arsenal can run in VirtualBox. However, some tricks are needed to have the latest version fully functional with VirtualBox.

For the ST’HACK Ethical Hacking Contest tonight in Bordeaux (France), all tools must be ready before the battle begins. MacBooks are armed, scripts are ready to be launched and beers are waiting in the fridge. During the preparation, BackTrack 5 R2 was installed on every teammate computers.

VirtualBox is of course the most suitable virtualization solution to run BackTrack. Unfortunately, with this latest version of BackTrack, the VirtualBox Guest Additions cannot be installed on a fresh new install. Fortunately, after some modifications everything can be fixed to compile these additions for the 3.2.6 Linux Kernel of BackTrack 5 R2.

Edit: VirtualBox Guest Additions solution updated with new fixes.

Download and Install

If you want support for USB 2.0 devices you must download and install Oracle VM Extension Pack for VirtualBox!

I will not describe the steps to install BackTrack on VirtualBox. A lot of tutorials can be found on the Internet to upgrade to BackTrack 5 R2 or to make a fresh install.

You can find bellow some screenshots about the VirtualBox configuration for my MacBook Air i7 1.8Ghz.

BackTrack 5 R2 64bits - Other Linux VirtualBox BackTrack 5 R2 64bits - RAM VirtualBox

BackTrack 5 R2 64bits - CPU VirtualBox BackTrack 5 R2 64bits - Acceleration VirtualBox

Issue #1 (solved): USB device descriptor error

usb 1-1: Device descriptor read/8, error -110 usb 1-1: Device descriptor read/64, error -110

Solution

The number of Processor for the Guest OS must be set to 1 or eventually 2… For example, my MacBook Air has a Core i7 inside, multithreading displays 4 virtual cores. So, I have to set a maximum of 2 cores to BackTrack VM Guest to fix this issue. (Even if the recommended number of cores VirtualBox displays is 4).

Issue #2 (solved): VirtualBox Guest Additions

After a fresh new install of BackTrack 5 R2, you should have no issues installing VirtualBox Guest Additions… So, before applying these patches, make sure the installation of VirtualBox Guest Additions fails.

After upgrading from an old version of BackTrack to BackTrack 5 R2, you can face some issues during the installation of the VirtualBox Guest Additions. These two kinds of errors can occur and lead to a vboxguest kernel extension impossible to load.

The headers for the current running kernel were not found. If the following module compilation fails then this could be the reason.

and

Building the main Guest Additions module ...fail! (Look at /var/log/vboxadd-install.log to find out what went wrong)

Both issues will result in:

Starting the VirtualBox Guest Additions ...fail! (modprobe vboxguest failed)

Solution
apt-get install linux-headers-$(uname -r) linux-headers xserver-xorg xserver-xorg-core file-roller # file-roller not needed
cd /usr/src/
tar jxf /usr/src/linux-source-3.2.6.tar.bz2
rm /usr/src/linux
ln -s /usr/src/linux-source-3.2.6 /usr/src/linux
rm /usr/src/linux-headers-3.2.6/include/asm
ln -s /usr/src/linux-source-3.2.6/arch/x86/include/asm /usr/src/linux-headers-3.2.6/include/asm
ln -s /usr/src/linux-headers-3.2.6 /lib/modules/3.2.6/build
ln -s /usr/src/linux-source-3.2.6/arch/x86/Makefile_32.cpu /usr/src/linux-headers-3.2.6/arch/x86/Makefile_32.cpu # Solution required for BackTrack x86 version by SphaZ

Make sure you have linux-source-3.2.6.tar.bz2 inside your /usr/src/ directory… Just in case you need it:

[wpfilebase tag=file id=28]

Ready to install the VBOXADDITIONS
Verifying archive integrity... All good.
Uncompressing VirtualBox 4.1.10 Guest Additions for Linux..........
VirtualBox Guest Additions installer
Removing installed version 4.1.10 of VirtualBox Guest Additions...
tar: Record size = 8 blocks
Removing existing VirtualBox DKMS kernel modules ...done.
Removing existing VirtualBox non-DKMS kernel modules ...done.
Building the VirtualBox Guest Additions kernel modules
Building the main Guest Additions module ...done.
Building the shared folder support module ...done.
Building the OpenGL support module ...done.
Doing non-kernel setup of the Guest Additions ...done.
You should restart your guest to make sure the new modules are actually used
Installing the Window System drivers
Installing X.Org Server 1.7 modules ...done.
Setting up the Window System to use the Guest Additions ...done.
You may need to restart the hal service and the Window System (or just restart
the guest system) to enable the Guest Additions.
Installing graphics libraries and desktop services components ...done.

Good job, now reboot and enjoy adaptative screen resolution, smooth mouse moves, folder sharing and copy/paste from Host to Guest and vis versa.

BackTrack 5 R2 Running on my MacBook Air i7 with the VirtualBox Guest Additions

Related terms: