[HOWTO] Install VirtualBox 4.0 in Fedora 15

Here is how you can install VirtualBox in Fedora 15. Open up the terminal and type in the following commands (make sure you have enabled sudo for your user):

wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | rpm --import -
sudo wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo --output-document=/etc/yum.repos.d/virtualbox.repo
sudo yum install VirtualBox-4.0 dkms

Hope this helps.

[HOWTO] Install VirtualBox 4.0 Final in Fedora

To install VirtualBox 4.0 in Fedora, first make sure you have removed old version of virtualbox and then open the terminal and type in su and enter password to login as root and type the following commands:

wget http://download.virtualbox.org/virtualbox/rpm/fedora/virtualbox.repo --output-document=/etc/repos.d/virtualbox.repo
yum update
yum install VirtualBox-4.0

VirtualBox will be installed and ready to use.

Hope this helps.

[HOWTO] Setup a Minimal Ubuntu LAMP server (with ssh server)

In this article, I will describe how I went about to install the bare minimum LAMP server using Ubuntu Minimal installation iso. I downloaded Maverick Meerkat version of Minimal CD image from the Minimal CD Image Download Page. You can use the server ISO but you may end up with unwanted packages and you will need to download the whole ~700 MB ISO to start, while Minimal CD is just ~13MB. Also, since the Minimal CD downloads the latest packages from the repos during installation, you need not update immediately further saving data volume.

I am installing inside VirtualBox 4.0 Beta. However, these instructions should apply to other Virtualization solutions or even a physical machine.

Boot into the computer with the CD Image (either burn it to business card CD-ROM or normal CD-ROM if using Physical Machine otherwise just mount inside VirtualBox) and follow the on-screen instructions and select appropriate settings that apply to you. At the last stages of the installation, you will be asked to select packages, select none. It will complete installing the basic packages and install Grub and reboot.

After reboot, you will be able to login. After logging in, enter the following command:

sudo apt-get install mysql-server phpmyadmin ssh

The above command should install the following components:

At the end of the installation, just select appropriate settings and setup passwords.

Now, when you launch a browser in another machine, you can open http://IP.OF.THE.MACHINE and you will see that system is ready, if everything went right. The installed size is less than 1GB (excluding swap).

Hope this helps.

[HOWTO] Properly install VirtualBox 4 beta in Ubuntu/Debian/Linux Mint (and other Debian/Ubuntu derivatives)

I downloaded deb of VirtualBox beta 1 from the beta packages page of Oracle website and installed it. However, while launching Virtual Machines created with Oracle VirtualBox 3.x (closed source version), I got the following error:

Failed to open a session for the virtual machine [machine name].
A virtual device is configured in the VM settings but the device implementation is missing.
A possible reason for this error is a missing extension pack. Note that as of VirtualBox 4.0, certain features (for example USB 2.0 support and remote desktop) are only available from an ‘extension pack’ which must be downloaded and installed separately (VERR_PDM_DEVICE_NOT_FOUND).

Result Code:
NS_ERROR_FAILURE (0x80004005)
IConsole {515e8e8d-f932-4d8e-9f32-79a52aead882}

It was clear that it requires an extension pack. I went back to the download page and found an extension pack named “Oracle_VM_VirtualBox_Extension_Pack-4.0.0_BETA1-68572.vbox-extpack” (newer versions may be available now so name may be different) and downloaded it. I installed it by double clicking it. It opens with VirtualBox by default (if it doesn’t, open with and select VirtualBox). The following error popped up:

Failed to install the Extension Pack /path/Oracle_VM_VirtualBox_Extension_Pack-4.0.0_BETA1-68572.vbox-extpack.
Failed to locate load the main module (‘/usr/lib/virtualbox/ExtensionPacks/Oracle_VM_VirtualBox_Extension_Pack/linux.x86/VBoxPuelMain.so’): VERR_FILE_NOT_FOUND.

Result Code:
NS_ERROR_FAILURE (0x80004005)
IExtPackManager {8104df65-74d6-4e33-b374-50aa062b4afd}

When I tried to launch a Virtual Machine, I got the previous error. However, when I tried to reinstall the Extension, I got the following error:

Extension pack ‘Oracle VM VirtualBox Extension Pack’ is already installed. In case of a reinstallation, please uninstall it first.

I learned from WebUpd8 that libstdc++5 was required for it. So, I just installed it by typing the following in terminal:

 sudo apt-get install libstdc++5

Then, after restarting VirtualBox, I was able to launch my Virtual Machines again.

[HOWTO] Enable sound in Mac OS X Snow Leopard 10.5.x or 10.6.x running in VirtualBox

I have recently installed Mac OS X Snow Leopard 10.6.3 with iATKOS 3 v2 disk as guest OS in VirtualBox 3.2.12 with Debian host. After fixing the video resolution issue, I noticed that there was no sound. However, VirtualBox Forum user OmegaX has written a sound driver for Mac OS X 10.5.x and 10.6.x. It can be downloaded from here. Since I don’t have Xcode installed, and since I did not want to go through the hassle of installing the kext manually, I downloaded the binary installer, unpacked it by double clicking on it and installed it. It seems to take forever, but it installs successfully. The sound is working fine after a reboot.

[HOWTO] Increase/Change Resolution of Mac OS X Leopard inside VirtualBox

I have installed iATKOS S3 v2 inside VirtualBox running on Debian. It can be simply installed like any other Operating Systems, but if you choose Operating System as Mac OS X Server, you must uncheck Enable EFI in the settings dialog.

If you wish to install, make sure to install latest VirtualBox (at least v3.2.x) first.

After the installation is ready, I was having problems with resolution. The only resolution that was available was 1024×768. To change it, I performed the following process.

I. Change com.apple.Boot.plist
1. Open up Finder from the dock (left most icon by default).
2. Open the Partition where you have installed Mac OS X under Devices.
3. Now, if you have an Extras directory in root, look for com.apple.Boot.plist. If you don’t, go to /Library/Preferences/SystemConfiguration/. You should see com.apple.Boot.plist
4. Copy the file com.apple.Boot.plist to Desktop.
5. Open the file on the Desktop with text editor (TextEdit).
6. Look for the following text:


If this value exists, the next line should have something like this:


Change it to whatever resolution your monitor supports.
If the value does not exist, add the following before </dict>

        Graphics Mode

Make sure, you have entered proper resolution for your monitor.

The following is my complete com.apple.Boot.plist:

	Kernel Flags
	Boot Graphics
        Quiet Boot
        Graphics Mode

7. Save the file to Desktop and close TextEdit.
8. Now, drag the file on the Desktop to the folder you copied it from. Confirm to Authenticate and Enter your password. Confirm to replace file.
9. Shut down Mac OS X.

II. Add Custom Video Mode as extradata to VirtualBox Configuration
1. Note your Virtual Machine Name for Mac OS X and quit VirtualBox. It is the name displayed in the Left Pane of the VirtualBox window.
2. Now, open up Terminal (or command prompt if you are using Windows) and run the following command (not as it is, make sure to make modifications. See below):

VBoxManage setextradata "Virtual Machine Name" "CustomVideoMode1" "_required_X_resolution_X_colordepth"

For example, if you have a virtual machine named “Mac Test” and want to set a resolution of 1440×900, you must run the following command:

VBoxManage setextradata "Mac Test" "CustomVideoMode1" "1440x900x32"

Now, start VirtualBox and start the Virtual Machine, Mac OS X should now use the new resolution.

Hope this helps.

[HOWTO] Setup a Live Testing Environment for Ubuntu Daily Builds right from the Harddisk

If you are keen about the changes in the next version of Ubuntu, 11.04 (Natty Narwhal), and want first hand experience, you can setup your own live testing environment which boots right from the harddisk. You can of course test the ISOs in Virtualbox, but if your card is not supported for Virtualbox 3D, you won’t be able to test the new Ubuntu Unity interface.

Computer running Linux with Internet Access
The computer must have graphics card supported by default by Ubuntu

I am assuming you are running another copy of Ubuntu. If the instructions don’t actually fit with your system, feel free to do whatever applies to your distro.

Getting the latest CD Images
Ubuntu 11.04 Natty Narwhal is under heavy development. The CD images are updated daily for users and developers to test. They are available here. However, if you download full ISO images daily, you will be wasting a lot of data transfer and time. Instead, you can download the changes only using zsync. Here is how.

Open up the terminal and install zsync:

sudo apt-get install zsync

Now, go to the daily images page and look for .zsync files of the ISO you want to try. For instance, if you want to try Ubuntu 11.04 32bit, you will need the zsync file natty-desktop-i386.iso.zsync. Don’t download the zsync file though. You will just need the URL to the zsync file. To get that on Firefox, right click and click “Copy Link Location”.

Now, you will need a directory where you want to download the images. Create a directory and make sure about 2 GB of space is available in the drive. Then, just open up the terminal and change to that directory and type in the following:

zsync http://cdimage.ubuntu.com/daily-live/current/natty-desktop-X.iso.zsync

where X is one of amd64+mac, amd64, i386, powerpc+ps3 or powerpc.
(The second part of the above command is the link you copied in the above step.)

Now, whenever you wish to get the latest Ubuntu ISO image, just run the same command from the same directory and your ISO will be updated. zsync will download only the changed parts from the server and the download will require less data transfer and hence will be faster.

Setting it up to boot
When you have the latest ISO, you will need to test them by booting. As I mentioned earlier, you could use Virtualbox but it may not support your graphics card for 3D and hence testing Unity may not be possible. Another program you can use is “Startup Disk Creator” (also known as usb-creator-gtk), but it only lets you create USB disks. If you have USB disks and don’t mind writing lots of files to it on a daily basis (assuming you will be testing all the daily builds), you could use that. However, USB Flash drives are prone to failure if used in that way.
The program we are going to use is unetbootin. It allows you to setup booting ISOs right from the Harddisk. It is available in the repositories in most Linux distributions but the latest version may not have hit the repositories yet, so it is recommended to download it from the official page. But it is recommended to install the one from your repositories too so that the dependencies are installed.

Make it executable by doing a chmod +x or by right clicking the downloaded file and selecting properties and checking the “Allow executing file as program” in Permissions tab.

Now, launch unetbootin and select the DiskImage option (and not the distribution) and browse to locate the latest daily ISO you downloaded using zsync. Select Type as Hard Disk and Drive as / and click OK.

When done, reboot and hold on Shift when the computer just starts to bring up the Grub menu. In the Grub menu, select the “Unetbootin” entry (and not the other ones, they may not work).

To setup the latest downloaded ISO again, run Unetbootin and uninstall the existing entry and repeat the same process.

Note: If you are using this setup, skip any updates to grub.

Happy testing.

[SOLVED] Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again. Stop.

I was trying to run Oracle Virtualbox in my Debian testing installation in which I have just installed Ubuntu Natty Kernel from Ubuntu repositories. I got an error followed by a dialog prompting me to run:
/etc/init.d/vboxdrv setup
as root.

However, it could not compile the kernel modules and I got the following error:

Uninstalling modules from DKMS
removing old DKMS module vboxhost version 3.2.10

——– Uninstall Beginning ——–
Module: vboxhost
Version: 3.2.10
Kernel: 2.6.32-5-686-bigmem (i686)

Status: Before uninstall, this module version was ACTIVE on this kernel.

– Uninstallation
– Deleting from: /lib/modules/2.6.32-5-686-bigmem/updates/dkms/
– Original module
– No original module was found for this module on this kernel.
– Use the dkms install command to reinstall any previous module version.

– Uninstallation
– Deleting from: /lib/modules/2.6.32-5-686-bigmem/updates/dkms/
– Original module
– No original module was found for this module on this kernel.
– Use the dkms install command to reinstall any previous module version.

– Uninstallation
– Deleting from: /lib/modules/2.6.32-5-686-bigmem/updates/dkms/
– Original module
– No original module was found for this module on this kernel.
– Use the dkms install command to reinstall any previous module version.


DKMS: uninstall Completed.

Deleting module version: 3.2.10
completely from the DKMS tree.
Attempting to install using DKMS

Creating symlink /var/lib/dkms/vboxhost/3.2.10/source ->

DKMS: add Completed.
You can use the –kernelsourcedir option to tell DKMS where it’s located, or you could install the linux-headers-2.6.37-6-generic-pae package.
Failed to install using DKMS, attempting to install without
Makefile:159: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR= and run Make again. Stop.

I realized that I had just installed linux-image package only and not installed linux-headers while manually installing packages. This can be avoided by installing the corresponding headers. An easy way to do so is to run the following command:

sudo apt-get install dkms
sudo apt-get install linux-headers-`uname -r|cut -d'-' -f3`-`uname -r|cut -d'-' -f4`

If you are using the older kernel and not the latest version available in the repost\itory, run the following:

sudo apt-get install dkms
sudo apt-get install linux-headers-`uname -r`

If you are on Debian, sudo may or may not be installed and it may or may not be configured for your user. Just use su to login as root and run the commands without sudo.

Hope this helps.

[HOWTO] Install Virtualbox on Linux Mint Julia with USB Support and Shared Folders

There are many Virtualization solutions that run on Linux and of course Linux Mint. Oracle Virtualbox is a virtualization software available for Linux, Solaris, Windows and Mac, . It is available from the Linux Mint Julia Repositories and can be installed directly via Software Manager. However, if you install the open source version i.e. virtualbox-ose package, you will not be able to connect your USB devices and share folders between Guest and Host machines. File sharing can be set up in other ways, but if you wish to use one of your USB devices which has no Linux drivers, you may need to install Windows inside Virtualbox and connect your devices so that you can install drivers inside. In that case, you will need to install closed source edition of Virtualbox i.e. virtualbox-nonfree.

After you install virtualbox-nonfree, you will be able to run and install Guest operating systems inside. However, this version may nag you about updates being available. Linux Mint repositories will be updated regularly and you will be able to install latest version so you can disable the updates checking in Virtualbox>File>Preferences>Update.

[SOLVED] VirtualBox, LTSP, “SMBus base address uninitialized – upgrade BIOS or use force_addr=0xaddr”

As I have mentioned in the previous post, I was experimenting with LTSP on my Ubuntu 10.04 Lucid Lynx Alpha installation. I set up ltsp client and then created a diskless VirtualBox Virtual Machine with Network Boot as First Boot Option. I tried to boot it and it an error came up. It said:

SMBus base address uninitialized - upgrade BIOS or use force_addr=0xaddr

and just froze there.
Since I have Core 2 Duo, I set up two processors in the System>Processor. I just set it back to one processor and despite of the error, the LTSP server booted successfully.