NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.
Forum Discussion
chirpa
Mar 07, 2009Luminary
Running VirtualBox VM host on ReadyNAS Pro
What is VirtualBox?
So, I got bored while laundry was going... and decided to see how well a virtual OS would run on the Pro. My first choice of VM was VirtualBox, just cause I'm familiar with it after using it for ages, plus its open and free :) Eventually, I may look into VMWare as well.
After a bit of messing around, got it installed. Since the system is based off of Debian, was easy to get VirtualBox itself there (deb package). The trickiest part was getting the kernel modules required installed (see end of post).
In the end, I've got Windows 2003 R2 running on my Pro, interacting with it via RDP, and I am happy with the performance. I've added an extra 1GB memory (for a total of 2GB). I assigned 1GB of ram to my virtual OS, which still leaves the default configuration of 1GB for the NAS itself (which is more than enough still, 800MB+ is always cached).
I made a 10GB virtual disk to install the OS on. If I need more space later for extra applications, I can just add another virtual drive to that installation. And since I always like a bit extra security, I went a bit beyond the usual, and also have TrueCrypt running full disk encryption in the virtual OS. So no one can even boot and read the data in that OS without my bootup password.
I don't really have any screenshots to show, just a standard Windows installation. Here is a few of the steps I used while creating the VM on the console:
VirtualBox 3.1 has changed the CLI configuration. Until I update this how-to, please reference this: http://www.uhleeka.com/blog/2009/12/vir ... 9-04-host/
With the OS booted up and just sitting at the desktop, top reports:
Ad-hoc installation of VirtualBox. Should work for RAIDiator 4.2.4. Download links for the kernel modules, for those who don't want to go through the mess of compiling them.
So, I got bored while laundry was going... and decided to see how well a virtual OS would run on the Pro. My first choice of VM was VirtualBox, just cause I'm familiar with it after using it for ages, plus its open and free :) Eventually, I may look into VMWare as well.
After a bit of messing around, got it installed. Since the system is based off of Debian, was easy to get VirtualBox itself there (deb package). The trickiest part was getting the kernel modules required installed (see end of post).
In the end, I've got Windows 2003 R2 running on my Pro, interacting with it via RDP, and I am happy with the performance. I've added an extra 1GB memory (for a total of 2GB). I assigned 1GB of ram to my virtual OS, which still leaves the default configuration of 1GB for the NAS itself (which is more than enough still, 800MB+ is always cached).
I made a 10GB virtual disk to install the OS on. If I need more space later for extra applications, I can just add another virtual drive to that installation. And since I always like a bit extra security, I went a bit beyond the usual, and also have TrueCrypt running full disk encryption in the virtual OS. So no one can even boot and read the data in that OS without my bootup password.
I don't really have any screenshots to show, just a standard Windows installation. Here is a few of the steps I used while creating the VM on the console:
VirtualBox 3.1 has changed the CLI configuration. Until I update this how-to, please reference this: http://www.uhleeka.com/blog/2009/12/vir ... 9-04-host/
# Creating the Virtual Machine.
$ VBoxManage createvm -name "Windows2003" -register
$ VBoxManage modifyvm "Windows2003" -memory "1024MB" -acpi on -boot1 dvd -nic1 nat
$ VBoxManage createvdi -filename "/c/backup/VirtualBox/Windows2003.vdi" -size 10000 -register
$ VBoxManage modifyvm "Windows2003" -hda "/c/backup/VirtualBox/Windows2003.vdi"
$ VBoxManage registerimage dvd /c/backup/VirtualBox/Windows2003Ent.iso
$ VBoxManage modifyvm "Windows2003" -dvd /c/backup/VirtualBox/Windows2003Ent.iso
$ VBoxHeadless -startvm "Windows2003" &
# Connected via Remote Desktop at this point.
# After the installation, first page requires Ctrl-Alt-Del, so I sent the keycodes.
$ VBoxManage controlvm "Windows2003" keyboardputscancode 1d 38 53
# System is up and running, time to install GuestAdditions for better video, etc.
$ wget http://download.virtualbox.org/virtualbox/2.2.2/VBoxGuestAdditions_2.2.2.iso
$ VBoxManage registerimage dvd /c/backup/VirtualBox/VBoxGuestAdditions_2.2.2.iso
$ VBoxManage controlvm "Windows2003" dvdattach /c/backup/VirtualBox/VBoxGuestAdditions_2.2.2.iso
With the OS booted up and just sitting at the desktop, top reports:
top - 16:17:10 up 1 day, 17:58, 1 user, load average: 0.00, 0.01, 0.00
Tasks: 93 total, 1 running, 92 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.7%us, 0.2%sy, 0.0%ni, 99.2%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 2072432k total, 2020100k used, 52332k free, 6120k buffers
Swap: 1048536k total, 144k used, 1048392k free, 784620k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
10297 root 20 0 1104m 1.0g 4720 S 4 52.5 57:31.53 VBoxHeadless
12792 root 20 0 46092 9520 1720 S 1 0.5 59:54.51 motion
12196 root 20 0 9196 7688 980 S 0 0.4 0:57.72 wastesrv
1 root 20 0 1948 600 508 S 0 0.0 0:01.30 init
Ad-hoc installation of VirtualBox. Should work for RAIDiator 4.2.4. Download links for the kernel modules, for those who don't want to go through the mess of compiling them.
$ mkdir /lib/modules/`uname -r`/miscOr, if you want to compile the kernel modules yourself:
$ cd /lib/modules/`uname -r`/misc
$ wget http://www.readynas.com/contributed/chirpa/modules/virtualbox/pro/vboxdrv.ko
$ wget http://www.readynas.com/contributed/chirpa/modules/virtualbox/pro/vboxnetflt.ko
$ echo "deb http://download.virtualbox.org/virtualbox/debian etch non-free" >> /etc/apt/sources.list
$ wget -q http://download.virtualbox.org/virtualbox/debian/sun_vbox.asc -O- | apt-key add -
$ apt-get update
$ apt-get install virtualbox-2.1
$ /etc/init.d/vboxdrv start
envyious:/c/backup# echo "deb http://download.virtualbox.org/virtualbox/debian etch non-free" >> /etc/apt/sources.listInstall of VirtualBox 2.2.2, before Sun updates the Debian Repository...
envyious:/c/backup# wget -q http://download.virtualbox.org/virtualbox/debian/sun_vbox.asc -O- | apt-key add -
envyious:/c/backup# apt-get update && apt-get install build-essential
...
Setting up build-essential (11.3) ...
envyious:/c/backup# wget -q http://www.readynas.com/download/GPL/RNDP6xxx_4.2.4_WW_src.zip
envyious:/c/backup# unzip -q RNDP6xxx_4.2.4_WW_src.zip -d ./GPL
envyious:/c/backup# cd GPL/linux-x86-2.6/
envyious:/c/backup/GPL/linux-x86-2.6# make && make prepare
...
envyious:/c/backup/GPL/linux-x86-2.6# ln -s /c/backup/GPL/linux-x86-2.6/ /usr/src/linux
envyious:/c/backup/GPL/linux-x86-2.6# KERN_DIR=/usr/src/linux
envyious:/c/backup/GPL/linux-x86-2.6# apt-get install virtualbox-2.1
...
Setting up virtualbox-2.1 (2.1.4-42893_Debian_etch) ...
Adding group `vboxusers' (GID 101) ...
Done.
Messages emitted during module compilation will be logged to /var/log/vbox-install.log.
Success!
Starting VirtualBox kernel module: done.
envyious:/c/backup/GPL/linux-x86-2.6# cd
envyious:/c/backup/GPL/linux-x86-2.6# VBoxManage list vms
VirtualBox Command Line Management Interface Version 2.1.4
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
# wget -q http://www.readynas.com/download/GPL/RNDP6xxx_4.2.4_WW_src.zip
# unzip -q RNDP6xxx_4.2.4_WW_src.zip -d ./GPL
# cd GPL/linux-x86-2.6/
# make && make prepare
# ln -s /c/backup/GPL/linux-x86-2.6/ /usr/src/linux
# export KERN_DIR=/usr/src/linux
# apt-get install libfontconfig1 libglib2.0-0 libice6 libsdl1.2debian libsm6 libx11-6 libxcursor1 libxext6 libxi6 libxmu6 libxrandr2 libxrender1 libxslt1.1 libxt6 python2.4
# wget -q http://download.virtualbox.org/virtualbox/2.2.2/virtualbox-2.2_2.2.2-46594_Debian_etch_i386.deb
# dpkg -i virtualbox-2.2_2.2.2-46594_Debian_etch_i386.deb
Setting up virtualbox-2.2 (2.2.2-46594_Debian_etch) ...
Recompiling VirtualBox kernel module: done.
Starting VirtualBox kernel module: done.
441 Replies
Replies have been turned off for this discussion
- berkut1Tutor
WhoCares? wrote: You're right, libcrypt.so seems to be missing from 4.2.11 whereas it was part of 4.2.9. You can get it by doing: apt-get update
apt-get install libc6-dev
Hmm, could this be a problem with the GPL for 4.2.11?nas3:/backup/CDs# apt-get update
Ign http://www.readynas.com 4.2.10/ Release.gpg
Get:1 http://ftp.debian.org etch Release.gpg [1033B]
Ign http://www.readynas.com 4.2.10/ Release
Ign http://www.readynas.com 4.2.10/ Packages/DiffIndex
Hit http://ftp.debian.org etch Release
Ign http://www.readynas.com 4.2.10/ Packages
Hit http://www.readynas.com 4.2.10/ Packages
Ign http://ftp.debian.org etch/main Packages/DiffIndex
Hit http://ftp.debian.org etch/main Packages
Fetched 1B in 1s (1B/s)
Reading package lists... Done
It is listing release/packages for 4.2.10 instead of 4.2.11.WhoCares? wrote: Maybe you could try to remove libc6-dev using "apt-get remove libc6.dev" and re-installing it? As an alternative you could try to apt-get install aptitude
aptitude download libc6-dev
dpkg -i libc6-dev_2.7-18lenny2_i386.deb[/code
Unfortunately this suggestion did not work as well. I am also getting warnings about these packages cannot be authenticated. Is this a problem?
At this point would it be a good idea to do a factory reinstall and start afresh? In my naive efforts I may have missed some other important points. The system I'm working on is a new Pro which was upgraded to 4.2.11 with no add-ons installed. I've read the forum the as carefully as I could and used Mackila's instructions up to the point of running VboxManage which is were I've run into the missing libc6 problem. - chirpaLuminaryTry editing your /etc/apt/sources.list, and change references for 4.2.10 to 4.2.11.
- berkut1Tutor
chirpa wrote: Try editing your /etc/apt/sources.list, and change references for 4.2.10 to 4.2.11.
Your suggested change resulted in:nas3:~# apt-get update
Get:1 http://ftp.debian.org etch Release.gpg [1033B]
Get:2 http://ftp.debian.org etch Release [67.8kB]
Get:3 http://ftp.debian.org etch/main Packages [5477kB]
Ign http://www.readynas.com 4.2.11/ Release.gpg
Ign http://www.readynas.com 4.2.11/ Release
Get:4 http://www.readynas.com 4.2.11/ Packages [5783B]
Fetched 5552kB in 34s (160kB/s)
Reading package lists... Done
I then performed the following on a newly built drive:
apt-get install build-essential
apt-get install bzip2
apt-get install lmza
cd /c/backup
wget http://www.readynas.com/download/GPL/RNDP6xxx_4.2.11_WW_src.zip
unzip -q RNDP6xxx_4.2.11_WW_src.zip -d ./GPL
cd GPL/linux-2.6.33.4/
make clean
make oldconfig
make all
ln -s /c/backup/GPL/linux-2.6.33.4/ /usr/src/linux
KERN_DIR=/usr/src/linux
cd /c/backup
mkdir virtualbox
cd virtualbox
wget http://download.virtualbox.org/virtualbox/3.2.2/VirtualBox-3.2.2-62298-Linux_amd64.run
chmod 755 VirtualBox-3.2.2-62298-Linux_amd64.run
./VirtualBox-3.2.2-62298-Linux_amd64.run
apt-get install lib64stdc++6
apt-get install lib64z1
cd /c/backup
mkdir CDs
cd CDs
# copied target OS image here
# Test the Virtualbox
VBoxManage list hostinfo
Execution of the VBoxManage line still resulted inVBoxManage list hostinfo
/opt/VirtualBox/VBoxManage: error while loading shared libraries: libcrypt.so.1: cannot open shared object file: No such file or directory
If I again attempt to load the apparently missing library I get# apt-get install libc6-dev
Reading package lists... Done
Building dependency tree... Done
libc6-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 43 not upgraded.
At this point I'm not sure what I am doing wrong in the install - as it appears everything needed is in place. - chirpaLuminaryTry this:
# apt-get --reinstall install libc6-amd64
The 32-bit libcrypt.so is in the root image, but not the 64-bit one. - berkut1Tutor
chirpa wrote: Try this: # apt-get --reinstall install libc6-amd64
The 32-bit libcrypt.so is in the root image, but not the 64-bit one.
Awesome! - That did the trick.
Thanks - berkut1TutorFYI
For those of you wishing to install Windows 2K/NT/XP it appears that the Windows Intel SATA driver "F32.IMA" is no longer available from Intel as referenced in chirpa's Virtualbox WinXP SATA install link Windows SATA Support. Nor could I find it anywhere on the web. The work around to creating a floppy image of the SATA drivers is described in How to install Windows 2000/XP/2003 guests with SATA support
To create the image on the Pro I needed mtools:apt-get install mtools
I then copied the zip file from the Option 3b - unofficial drivers location and put them into my working floppy directory.
From there I followed the recipe to make the floppy image.mkdir floppy
cd floppy
# copy the XP AHCI v7.0.0.1020 for ICH8 Driver zip to the target folder
cp <source-path> .
unzip AHCI_v7.0.0.1020_for_ICH8.zip
dd if=/dev/zero of=./ich8.img bs=1k count=1440
mformat -i ich8.img -f 1440 ::
mcopy -i ich8.img "AHCI v7.0.0.1020 for ICH8"/* ::
Once I had the floppy image I was able to complete the creation of my WinXP guest OS VM described in the Windows SATA Support page. - chirpaLuminaryI probably have a copy of the file somewhere, if so, I'll upload it locally here later.
Also, the VB guys are quick, VB 3.2.4 is out now; http://www.virtualbox.org/wiki/Changelog - ahpsi1TutorIs this the file you are looking for -> http://wiki.inisec.com/index.php/File:F32.IMA?
- berkut1Tutor
ahpsi wrote: Is this the file you are looking for -> http://wiki.inisec.com/index.php/File:F32.IMA?
Thanks for finding it. This will help out those who wish to skip the steps I had to go through to build a SATA driver floppy image. - berkut1TutorI've successfully have Windows XP running on my virutalbox v3.2.4. I've been successful in updating windows with all of the current security patches except for KB958869. This patches fixes a security hole with their GDI+ library. So the question I have is has anyone else had problems installing this patch on their WinXP guest? And if so where you able to resolve it?
Thanks
Related Content
NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology!
Join Us!