Tag Archive: VMWare


Installing Gentoo in a Fusion VM

The other day I installed Gentoo on an old Celeron 466MHz and it was quite an adventure.  Today, I’m attempting to install it in a far more useful capacity as a virtual machine under VMware Fusion.  The first thing I did was create a new virtual machine.  There is no template for Gentoo so I tweaked the settings a bit.  I gave it 512MB ram, 30GB hard drive and set it to “generic linux 2.6.X kernel”.  I set it to boot from the minimal ISO that I used to burn the CD for the other day. After I was booted up, I ran a couple of benchmarks.  Thankfully this system is several orders of magnitude faster than a Celeron 466MHz.

Using fdisk, I created my 3 partions:

/boot /dev/sda1

swap /dev/sda2

/        /dev/sda3

Then I did my mkfsing:

mke2fs /dev/sda1

mke2fs -j /dev/sda3

mkswap /dev/sda2 && swapon /dev/sda2

Now it was time to snag my stage file.  This time instead of wget, I used links:

links gentoo.org

I hit the downloads link, then hit the stages button next to i686 and found the most recent stage3-i686 tar.bz2 file and downloaded it.  After that, I untarred it:

tar -xpjf s<TAB>

Next, I changed snagged the latest portage via links and untarred that:

cd  usr

links distfiles.gentoo.org/snapshots

tar -xpjf p<TAB>

Then it’s time to chroot:

livecd / # mount -t proc proc /mnt/gentoo/proc

livecd / # mount -o bind /dev /mnt/gentoo/dev

livecd / # cp -L /etc/resolv.conf /mnt/gentoo/etc/

livecd / # chroot /mnt/gentoo /bin/bash

livecd / # env-update && source /etc/profile

Then I set the timezone:

cp /usr/share/zoneinfo/America/Los_Angeles /etc/localtime

After that, it’s time to fix up the hostname:

cd /etc

echo “127.0.0.1 gentoo.notanon.com gentoo localhost” > hosts

sed -i -e ‘s/HOSTNAME.*/HOSTNAME=”gentoo”/’ conf.d/hostname

hostname gentoo

Now for the kernel.  I didn’t do a lot of tweaking with the kernel this time around.  I just added ext2 support and a couple of extra modules I want to experiment with.

emerge gentoo-sources

cd /usr/src/linux

make menuconfig

time make -j2

make modules_install

cp arch/i386/boot/bzImage /boot/kernel

Then I editted the /etc/fstab to look something like this:

/dev/sda1 /boot ext2 noauto,noatime 1 2

/dev/sda3 / ext3 noatime 0 1

/dev/sda2 none swap sw 0 0

Then I installed cron, syslog, grub dhcpcd:

time emerge syslog-ng vixie-cron grub dhcpcd

rc-update add syslog-ng default

rc-update add vixie-cron default

After that it’s time to nano /boot/grub/grub.conf:

default 0

timeout 10

title Gentoo

root (hd0,0)

kernel /boot/kernel root=/dev/sda3

Then I ran grub and entered:

root (hd0,0)

setup (hd0)

quit

After this, supposedly it’s time to unchroot, cross my fingers and reboot:

exit

umount /mnt/gentoo/dev /mnt/gentoo/proc /mnt/gentoo/boot /mnt/gentoo

reboot

Alas, it didn’t work.  I’ve yet to nail a Gentoo installation on the first attempt but this time I was much closer.  I ended up finding a wiki on installing Gentoo in a VM.  I rebuilt the kernel with some of the suggestions that were stated in the wiki and that did the trick.

Feeling brave today, I decided to click the “upgrade” button this time when I started up Haiku.  I’m running VMWare 3.1.0 so I’m referring to when I start up VMWare and it asks me if I want to upgrade the VM to use newer features of 3.1.0.  The warning is that it will no longer work in older versions of Fusion once I push this button.  This is an acceptable risk to me since I don’t have any older versions.

When I first pushed the button, it was very uneventful and the dialog simply disappeared.  Maybe 15 seconds later, another one appeared asking if I’d like to replace my serial output file “serial-port.txt” since one already existed.  Sure why not?

After that, it took about 30 seconds and booted right up like nothing happened.  That’s a win in my book.  Time to break stuff…

First I’ll take a snapshot.  WOW!  By far the quickest snapshot I’ve ever taken of anything!  This only took all of 5 seconds.  On windows, I’ll get up and take a coffee break while I’m waiting for snapshots to finish and when I want to rollback I’ll stick that on before I go to bed(j/k, it’s not quite THAT bad).  A snapshot is no good of course if it can’t be restored sooooo let me test that out right now….twenty seconds later, it’s restored.  Oddly, it did ask me again if I wanted to replace the serial-port.txt file again.  Oh well, I don’t really care at this point.

Let’s try some peripherals.  A serial port oddly comes to mind.  The one I tried has a prolific chipset in it so nothing too exotic.  When I hooked it in via the VM, nothing happened.  No error, no message, no noise…nothing.   Doing a quick browser of the applications that come pre installed, I didn’t see anything resembling hyper terminal and from the command line, no minicom either.  Oh well, no huge surprises here.

While browsing for a program that could communicate with the serial port, I DID come across the activity monitor.  This thing is very impressive.  It refreshes several times per second and is very responsive.  On my system, it averages about 9% CPU usage and pegs at 64.2MB of ram.  That is LOW comparing to OS X that hogs up well over 512MB right on boot up.  Opening a terminal in Haiku brings the memory usage up to a whopping 72MB of ram in use.  8MB of ram for a terminal?  I can accept that.  OS X takes 10MB or so for me.  Bash is a bit of a pig from what I understand though so this can probably be optimized by using a different shell.

Next I noticed the “find” option in the menu.  In the couple of years I’ve had my Mac, I’ve become completely spoiled by the spotlight tool I have to admit.  I love having the results to my search show up as I find them.  But on the same note, I couldn’t POSSIBLY expect that kind of behavior out of an OS that will run on super light weight hardware.  That being said, I found the search to be really snappy.  I searched for “terminal” and had the results in less than 2 seconds.  I’d have to fill my poor system with a LOT of junk to really put this feature through it’s paces but I like what I see so far.

Haiku Terminal

Lastly, I want to create a WebPositive icon on my desktop.  As I mentioned in another post, I tried right clicking the icon in the Tracker and tried dragging the icon from the Tracker as well and that didn’t do the trick.  Next thing I did was to click “applications” in the tracker.  This gave me a directory listing so I dragged the icon out of there but then it was gone from that menu.  Hmmm…  I dragged it back and now tried to right click on it in the directory listing.  Voila!  That seems to have worked but it presents me with a somewhat overwhelming list of options that sound like they would do the job.  There is “copy to” which I probably don’t want to use since I’m assuming it would copy the entire application.  Then there is “duplicate” which made a copy of the entire application(or shortcut in this case) in the same directory.  Finally there is the “create link” which opens a sub menu allowing the link to be sent directly to a myriad of locations including the trashcan!?!  Why would you want to create a link in the trashcan?

Now that I have my WebPositive icon, I want to see how much ram Haiku’s web browser takes.  Keep in mind this browser does not support Flash and presumably a couple of other features but I DID jump into Google Docs and saw no problems at first glance and it seemed very responsive.  I did notice something else cool about Haiku in the course of this.  I opened up the ActivityMonitor and at first the ram was sitting at 122MB but as I’m typing this, I’m watching the ram usage count down and the cache usage count up.  It’s actively moving active ram into cache as I’m allowing it to idle.  Less than 2 minutes after I’ve stopped using the program, the active ram is down to 95MB of usage.  To me these is really nice and a refreshing change from Windows where applications tend to continually eat more memory.  When I click on WebPositive again, all the cache pops back into memory instantly and the usages goes back up to 120MB.  If I open up another program instead, the ram is free for that new program to use.  Everything in the background seems to get counted off into cache.

This second look at Haiku has given me far more appreciation for the effort the developers have gone through to make a compact and efficient, yet modern operating system.  I wish the other vendors would take a few hints to see how it’s done.

Does the world need another operating system?  That seemed to be the question that was asked when BeOS was first unleashed on the world in 1995.  When BeOS was ported to the x86 platform in 1998, I got a copy and gave it a try.  It was awesome!  I remember it having forward-looking features that the Mac platform only recently has added and stability that none of the current operating systems(at the time) could claim.  The problem was software however…  I had all but forgotten about BeOS as soon as I had discovered it since it didn’t have nearly enough applications for me to practically consider switching to it as a primary desktop platform.  From my understanding it did gain a small following in the pro audio world.  There were a few commercial audio applications that were released for it including one that I used to own, T-racks.

Fast forwarding to present day, what have the former BeOS developers been up to?  In a word, Haiku.  This new system continues in the spirit of BeOS in the sense that it has been designed from the ground up to be an efficient, integrated & complete “single vendor” open source system.  It’s not based on a Linux Kernel but instead has a Kernel written from scratch to integrate with the rest of the OS specifically.  This is a stark contrast to Linux where thousands of developers have written code in the Kernel and many more thousands have ported countless core applications over to the Linux platform which results in a mish mash of incompatibilities and less than ideal subtleties.  A better explanation of Haiku is available on their FAQ.

Haiku is distributed in several different formats.  There is a live CD version, a regular install CD and a VMWare image.  First I’m going to try out the VMWare image on my MacBook Pro…  I have VMWare Fusion 3.1.0 currently and I’m trying out the R1/alpha2 version of Haiku.  When I first try to open the VMWare image, it asks me if I want to upgrade the VM for better 3D performance, etc.  At this point, I’m going to decline and continue.  Upon boot up I’m presented with some eye candy icons and in less than 45 seconds, the machine is booted and ready to operate.  It is no surprise that VMWare tools is NOT installed and presumably does not exist so I’m keeping my fingers near the control-command keys for now.

After the machine is booted, the desktop comes up with the tracker and a few desktop icons as seen in the screen shot above.  Clicking on the “Haiku” icon, I’m greeted with a pop up window showing the eight items present at the bottom level of the hard drive.  Honestly it reminds me a bit of the older Macintosh System operating system.  On a side note, I recently read a very interesting article by Tom Pittman that describes a blueprint for a 21st century operating system and for some reason, Haiku made me think of that.  Anyhow, back to the 2nd icon now which is “Welcome”.  After clicking that icon, the dream fades back into reality and I end up waiting 15-20 seconds for a web browser to finally pop up with the welcome document in it.  I am drawn back in however when I type www.google.com into the web browser and find that not only does the network link work but Google pops up pretty darned fast.  I should mention that upon launching the web browser, the tracker application added a button, icon or whatnot to it with the name of the browser “WebPositve” in it.  I closed and relaunched the web browser and this time it popped up on the screen nearly instantaneously so I will excuse the slow initial start up.

Next I tried to pop up a terminal.  It loaded very quickly.  I wanted to add the terminal as an icon on my desktop but right clicking or dragging it from the tracker menu are not doing the trick.  Those are two of the most intuitive ways I could think of to accomplish the task but I’m probably missing something.  Whatever the case, ls works, top works and uname -a reveals:

Haiku shredder 1 r36769 May 8 2010 20:58:31 BePC Haiku

With that, I’m going to sign off for now and move on with some other tasks but so far my first taste of the Haiku OS is just as pleasant as I remember BeOS being.  It’s very easy to use, quite responsive and seems to have a lot of potential.  I sincerely wish the development team luck with this project.  The copyright shows that Haiku has been in development since 2001.  Wow!

What is the use of this new operating system?  What niche does it fill that hasn’t already been filled by Windows, Linux, Mac OSX, Android, etc?  First off, older hardware.  The system requirements of Haiku are incredibly low for a modern OS.  Apparently you can run it on something as poky as a Pentium II.  Second, it may be even easier to use than Mac OSX and to reiterate, it certainly has lighter hardware than Mac OSX.  Beyond that, I’m really not sure.  Reading the Haiku website, I cannot find any indication of where this operating system fits into the pecking order with the others.  It might be a good server platform since it appears to have some level of POSIX compliance and the kernel could be extremely secure since the development team is relatively small and because there are simply no exploits or vulnerabilities available for it.  It could also make a good platform for 2nd hand computers since it’s WAY easier than Linux and has light system requirements.  Only time will tell if Haiku is just another solution without a problem.

Powered by WordPress. Theme: Motion by 85ideas.