Power

When running VMware  and you want to  shut down or restart the guest OS, it is very tempting to sometimes just use the buttons in the “Power Toolbar”.  One thing you should realize is that shutting down or restarting your OS using these buttons is the equivalent of cutting off power to your PC and instantly shutting off.  Since this typically isn’t good practice and can lead to settings not being saved or more importantly, the loss of data you should always go through the OS’s shutdown procedure.

Then why do they put the buttons on the toolbar if they are useless you ask?  These buttons are configurable to do what you want.  You can set the buttons to go through the proper OS shutdown or restart procedures.  To change this setting, open VMware and click on the  VM menu and choose settings.  Once the settings menu is up, choose the “Options” tab  and click on the “Power” setting in the list on the left.  Here you can change the stop button from “Power Off” to “Shut Down Guest” and the restart button from “Reset” to “Restart Guest”.

These buttons work by telling the guest OS to run a shutdown or restart script and that requires VMware Tools to be installed on your guest OS.  Additionally, you can customize these scripts by launching VMware Tools in your guest OS and going to the “Scripts” tab.  here you can specify specific scripts you want run for the different events.

Following this process should give you a quick and easy way to shutdown or restart your virtual machine with one click instead of going through the menus.

Advertisements

Google Desktop Linux

If you have ever used the default search that you find in the file browser of Ubuntu or even the “find/whereis” function from the terminal you know that it can be very frustrating trying to locate a specific file on your system. Although, there are several utilities already available for Linux users to simplify and speed up file searches, I had not yet seen one that integrated searching files, documents, webpages, images and online videos all at the same time until Google released Google Desktop for Linux. This new app gives you all of the functionality mentioned above and is very customizable with minimum intrusion. There are two easy methods for installing Google Desktop.

  1. Download the .deb here.
  2. Add the Google repository to your list of repositories (instructions).

I recommend the second option since this will provide you with access to the latest Google software when it becomes available as well as notifying you as soon as important updates become available.

Google Desktop Preferences

Once you install Google Desktop and reboot, the application will autostart and begin indexing various folders on your HD. What’s nice about Google Desktop is that you can specify which locations you want to allow the application to index and which folders should be ignored. To do this, just launch the preferences window using the icon in the Gnome Panel. Another aspect to take into consideration is the amount of resources an application like this uses when indexing. Some other search apps for Linux can use 50+MB for search while I have not yet seen the Google Desktop search peak above ~15MB. The only drawback I see to this program is the load time associated with launching Firefox to view “all results” (top results appear in a quickview window). Follow the links above to check out test drive the software for yourself.


Speaker

In my previous post I showed you how to emulate an existing Windows install in Linux using VMware server. Now that you have your Windows OS running and you can run all your basic apps, it’s time to improve the functionality of your virtual OS by adding sound so that you can listen to music, watch videos, play games, etc. By default sound is disabled in the guest OS and I have read several websites that claim it is not possible to get sound working in VMware server. On the contrary, it is very easy to setup audio in the latest version of VMware Server. The following steps will show you how this can be done.

  1. Launch VMware as root: [gksudo vmware]
  2. Open the virtual machine you want to add sound to (the machine should not be powered on, if it is, shut down).
  3. Click “Edit virtual machine settings.
  4. Under the Hardware tab click “+ Add”.
  5. Choose “Sound Adapter” and click Next.
  6. Select Auto Detect from the drop down menu.
  7. Make sure “Connect at power on” is enabled.
  8. Click Finish.

Power on your machine and login. If you have VMware Tools installed, Windows should automatically detect your virtual audio drivers. You should now be able to hear audio and system beeps. You can also control the volume using both Windows’ volume control and any hardware volume control buttons you have. Keep in mind that the volume in your Guest OS is dependant on your Host OS. That means if your volume is muted in Linux, you will not hear anything in Windows even if you set Windows’ volume to max. Additionally, if your volume in Linux is only set to halfway, the loudest you can hear anything in Windows will also be halfway.

Additionally, if you want to enable the use of USB devices in your Guest OS, follow the same method as above and choose USB controller instead.


I promised before that I would do a write up of a simple way to run an existing install of Windows XP from within Linux. Many people run a virtual Windows install from within Linux which is pretty good but is sometimes a burden if you have an existing physical Windows install because you now have 3 operating systems that you need to move files across and most people want access to the same programs and settings in their virtual install of Windows as they have in their physical install. The process I outline below will be useful for Linux users that have an existing dual-boot setup and want the capability to access their existing Windows OS without having to go through the tedious reboot process.

As an engineering student using Linux, I have realized that some of the programs I need to use like Maple, Matlab, SolidWorks, etc. (I will show you some good alternatives to Maple and Matlab in a later post) are not available for use in Linux. This became quite annoying when I was constantly rebooting my computer and switching OSes. One solution to my problem was to create a virtual copy of Windows XP. I didn’t like this idea because it would require wasting double the hard drive space that the Windows OS files need, reinstalling all the software I need and configuring everything to the right settings. So I began searching for ways to virtualize an existing Windows partition and came across this site: Blackmh. Although this guide provides a lot of useful information for getting started, it did not work on my laptop (might work on yours) . Additionally, I figured many users don’t want to mess with figuring out the location of cylinder heads and what not, so I put together this guide that will help you quickly and easily setup your system.

1. Installing VMware:

The easiest way to do this is by using the Automatix installer. If you haven’t already installed Automatix, download and install it from here: Get Automatix, the install is very straight forward. Once, you have Automatix installed, run it and go to the Virtualization category. Here you want to select VMware Server and hit install and Automatix will take care of the rest.

2. Configuring VMware:

You need to run VMware as root so in the terminal window type:

gksudo vmware

You will now be prompted with the VMware Server Console. Make sure that “Local host” is selected and choose “Connect”. For easy setup, use the Virtual Machine Wizard by clicking on “Create a new virtual machine” and going through the following steps:

  1. Next
  2. Custom, Next
  3. Microsoft Windows (Choose Version, I use XP Professional), Next
  4. Choose a name and location, the default values are fine, Next
  5. For Processor Configuration I chose One Processor so that one core would be dedicated to each OS during virtualization, you can change this later. Next
  6. Access Rights did not make a difference, I did not make my machine private. Next
  7. Specify the amount of memory you want to allocate to the Guest OS. I dedicated half my memory, 512MB. However, when running simulations or using apps like SolidWorks it feels very slow so I plan to pickup 2GB after work tomorrow. Next
  8. For your Network Connection I recommend you use NAT (network address translation). This will be the easiest configuration since you will be sharing the same connection among both OSes. Bridged will allow each OS to use a separate connection but requires further configuration that I will not get into here. Next
  9. Choose BusLogic as your SCSI adapter. Next
  10. Choose “Use a physical disk”, Next
  11. Your “Device” should be the main disk that contains both your Linux partition and your Windows partition. Select “Use individual partitions”. Next
  12. Here select both your linux and windows partition (swap isn’t needed). Your linux partition is needed since only the first stage of GRUB resides on the MBR and GRUB will try to access your linux partition to load stage 2. Next
  13. Choose a Disk Filename, the default is fine. Finish

3. Configuring Windows

Before starting up your virtual machine follow these steps, I copied them from Blackmh’s site:

"Now reboot into Windows and set up another hardware profile for Vmware.
Start-> Control Panel-> System, click on Hardware tab and Hardware profiles. You will find Profile 1 (Current), highlight it and click Copy, give it new name, Vmware for instance and move it up.While at Hardware tab in System properties, you can disable driver signing.

One more thing to do. As you may know, work in Vmware machines is easier with Vmware tools. I took Vmware tools installation out of Vmware Server to spare you of downloading 100 MB + file and you can download it here. Unpack archive and put it somewhere on Windows partition."

While you are in Windows I recommend you install the SCSI drivers for the virtual SCSI controller that VMware uses. This is necessary because VMware acts as a virtual computer with virtual hardware. Windows has the drivers it needs to operate on your system but by running it in VMware you are virtually unplugging your HD and plugging it into a computer with different hardware specs. This can pose a problem when Windows can not find drivers to access the HD (since VMware uses a SCSI controller) and you will be presented with a BSOD error 0x0000007 on startup. You can either follow the Microsoft Knowledge Base article and try to work around this problem (I’ve seen little success) or you can follow my method:

  1. Download the VMware Server SCSI floppy image (I’ve extracted the files into a ZIP if you don’t have a floppy drive)
  2. I made a video of the driver install process that you can follow:

Installing VMWare SCSI Drivers

Click “Next” and “Finish” where the video leaves off.

Now reboot into Linux.

4. Getting ready to run the Virtual Machine

Launch VMware as root as explained above and choose local host. There should be a tab for the virtual machine you created earlier, select it.

VERY VERY IMPORTANT: Before running your virtual machine, ensure that your GRUB timeout is not set to zero. You can change the timeout by accessing /boot/grub/menu.lst and increasing the “timeout” value. Refer to my post on the GRUB Menu for more information. If you leave this value as zero, it is very likely that GRUB will automatically run Linux when you first start up. You should ***NEVER VIRTUALIZE YOUR CURRENT LINUX INSTALLATION***. This will corrupt your linux install and make it unusable. With that said, I will show you a way to avoid the GRUB menu all together later in this post.

Once you have ensured that your timeout is not set to zero and GRUB will give you time to choose the OS you want to boot go ahead and click “Power on this virtual machine”. The console screen should open up and you will see your computer booting up. Once this is done the GRUB menu should load and you can choose your Windows install that you want to boot.

At this point you will either be given a choice of which hardware profile you want to boot into (choose VMware) or your screen will hang at “Starting up…”. In my case it hangs at starting up. This had to do with the location that the windows boot files are located on your hard drive and the fact that GRUB did not point to the correct location.

Don’t worry there is a solution that I recommend, even for users who can successfully boot into Windows. Reboot your computer into Windows and use your Windows install CD to make a boot CD image. If you don’t know how to do this, google it, there are many guides explaining it. However, if you are using Windows XP Pro (may work for home), I have a boot disk image that you can download. Save this file to disk and note where you saved it.

Now in VMware you should be at the virtual OS summary screen. Towards the middle right you should see “Devices”. Double click on CD-ROM and under connection change the setting to “Use ISO image”. Click “Browse” and select the file you just downloaded or the boot image you made yourself and click OK. At this point, if your BIOS is setup to boot the CD first before any other device, VMware should automatically boot windows and never even enter the GRUB menu, saving you from accidentally booting your current Linux OS. If your BIOS is not setup to do this, Google how to do this for your specific computer.

You should now be good to go. You can power on your virtual machine and Windows should boot by default. Select the VMware hardware profile and the first time you run windows you may be asked to reactivate Windows. This is because Windows has detected your hardware having changed (VMware’s virtual hardware). The activation process is very simple and straight forward and you should not be asked to activate again when you do a physical reboot into Windows. The first time you login you will be bombarded by “Found New Hardware” screens. Ignore these and just run the VMware tools you downloaded earlier. Perform a virtual reboot and all your virtual hardware will be detected.

You can now use your existing Windows install from within Linux!

Here are a few screenshots of Windows running in Linux:

OS & Browser Detect page shows WinXP & IE7:

OS & Browser Detect

Beryl & VMware:

Beryl & VMware

SolidWorks Running in Linux (emulated):

SolidWorks Running in Linux

If you have any questions you can post a comment. I will do my best to answer them.


WARNING: I am in no way a computer engineer, the guide provided here is intended for people who know what they are doing, don’t blame me if something gets messed up.

With that said, I think the best way to learn is to backup any important data you have and not be afraid of having to reinstall the OS as long as you achieve your goal and learn something at the end of the day. This guide worked on a Thinkpad X60.


Intel Software

When thinking of Intel and operating systems, one of the first thoughts that comes to mind is “Wintel”; Intel computers running Windows. Nevertheless, Intel has been working very hard over the past years to get away from this image as much as possible and this involves giving the Open Source community full support. Whether it be in the form of providing hardware specifications ahead of a product release, developing drivers or helping develop kernels to improve performance, Intel is there backing Open Source.

It seems clear that Intel sees great opportunities when it comes to Open Source through their support of the community here as well as their efforts to promote its use globally. Take a look at Intel’s Software Network page dedicated to Linux and Open Source. Here you can find plenty of tools and resources that have improved open source development along with drivers for the latest Intel hardware.

However, the main highlight of this post is to give you something to really look forward to in the next release of Ubuntu, Gutsy Gibbon. As you may know, this latest release (due out October ’07) will include kernel 2.6.22-6.13. What exactly does this mean? This means that if you are running an Intel processor along with the latest kernel (2.6.21+), the CPU no longer has a fixed 1000Hz timer tick (dynticks). This will allow your CPU to go into even deeper idle modes where more power is saved.

Unfortunately, certain applications and processes don’t allow your CPU to achieve this deeper level of idle which results in more power usage and higher temperatures. Fortunately, Intel has developed software called PowerTOP designed to tell you which processes are using the most power to help you better manage your system’s power consumption:

PowerTOP

These developments will be welcomed by all users but especially those that run linux on their laptops and are looking for better battery life. It’s important to realize that there are dedicated teams of software developers at Intel working to improve both the performance and power consumption of our computers despite the fact that we don’t use the most mainstream OS.

In the end, it’s nice to see more support for linux from the hardware industry. Hopefully the steps that Intel has taken will show other hardware manufacturers that linux users are an important demographic and that their support for open source in the form of software and drivers is needed.

If you want to start increasing your battery life before Gutsy Gibbon is released, check out this blog.



Check out this video of the latest features to be added after the Compiz/Beryl merge. The effects look stunning, especially the cube reflection, very clean.


 

Tether

If you’ve had a Windows Mobile phone in the past you probably know that it can be a pain to tether your laptop to use the internet connection since you usually have to treat the phone as a modem and dial the access number, etc. With the Samsung Blackjack, this process is a piece of cake and has been simplified into 4 easy steps:

  • Connect your phone to your laptop using ActiveSync.

  • On your phone, launch “File Explorer” and navigate to the Windows folder.

  • Launch the application named “Internet Sharing”.

  • Choose “USB” as your connection and hit “Connect”.

That’s it. Just launch your internet browser to surf the web or open Outlook to sync your emails.

I have read that this is not against your user agreement from T-Mobile and I do not know anyone who has the Total Internet package and has been charged for tethering their phone. However, this is only allowed on certain plans for AT&T so consult your user agreement before you go racking up a huge phone bill.