My Blogs


Windows XP - Common Optimisation Issues

Friday, February 22nd, 2008

Quite often, a lot of the work I do with computers just involves giving the systems (mainly running Microsoft Windows XP or Vista) a general clean-up and speed-up, as they tend to slow down and clog up over time. I’ll try and run through a couple of things which you can do to speed your machine up as well as take you through the general process I go through with each clean-up job. For the purposes of this guide, I’ll be using Windows XP Media Center Edition 2005, however a lot of the points can be applied throughout the XP (and indeed Vista) family of systems.

Step One - Running Virus and Adware Scans

The reason why your PC could be slowing up may be that it has become infected with a virus or adware. The two terms are sometimes confused, as while both are programs that compromise your PC’s security, adware installs constant pop-up advertising and other annoying paraphernalia, whereas viruses are generally seen as more malicious programs that can physically harm your operating system and possibly stop your system from functioning.

To keep these nasty things away, I use a combination of two well-known programs that are both completely free - Lavasoft’s AdAware 2007 (adware scanner) and Alwil’s Avast! Home Edition (anti-virus). Avast will need registration, but this is just an email address so that they can send you a serial key.

Before installing Avast, make sure that you have uninstalled any other anti-virus programs, as these could interfere with Avast’s scanner. Also, before running scans, make sure that both programs are fully up-to-date with definitions and program files using their integrated update functions. I generally find that it’s best to run Avast outside of Windows on a boot-time scan, as this allows it to delete any unwanted files that are locked and in-use when the scan is running.

With those scans done and any nasty unwanted programs and files removed, you can then move on to the next stage and free up some disk space.

Step Two - Freeing Up Disk Space

Despite hard drives becoming faster, cheaper and larger - is seems that there will never be enough space to keep everyone’s music, documents and movies while also being able to install today’s resource-hungry operating systems (yes, I’m looking at you Windows Vista…) and games. Sometimes it can help to free up disk space that Windows uses for various purposes - temporary files, caches, Recycle Bin, Windows Media Player sync files among others. This space is pretty much wasted if the system is running properly and as it should be.

You can run the disk clean-up utility by going to Start –> All Programs –> Accessories –> System Tools. This will give you a window that looks similar to the one on the right.

Before you go clearing all of those temporary files, you can also free up some space by deleting all but the most recent System Restore checkpoint. While there is some danger in doing this - as if something does go wrong with your machine, there will only be one checkpoint to choose from - but if the system is running happily and you haven’t made any major hardware or software changes in a month or so, the previous restore points will not be needed. You can switch to the More Options, then click on Clean Up in the System Restore section of the screen to clear the restore points. My advice would be that if you’re not absolutely sure that your system is running properly, don’t delete the restore points. Saving about 2GB of disk space is a big price to pay if the system suddenly bites the dust without warning.

After clearing the restore points, you can head back over to the main Disk Cleanup tab. I generally check every box with the exception of “Compress Old Files”, as I know that I won’t need the data - I still have my Microsoft Office installation CD for example, so there is no need to keep the cached Office install information. As with the restore points, if you’re not sure, don’t delete the files. Clicking on OK will confirm your choices and will clean the ticked boxes.

Step Three - Defragmenting

A common issue with Windows is the ability for it to spread files right across the hard drive in tiny pieces. To give you an analogy of what this is like for the hard disk to read fragmented files, imagine a vinyl turntable having to reposition it’s needle every fraction of a second to read the next piece of music from the vinyl. Defragmentation is just the process of bringing these tiny parts of files back together and gluing them into one easily-accessible place on the hard drive.

To start the disk defragmenter, go to Start –> All Programs –> Accessories –> System Tools –> Disk Defragmenter. Clicking on your C drive and then clicking Analyse will analyse the drive for fragmented file and will produce something like the screenshot below:

Windows will normally tell you that the drive doesn’t need defragmenting, however I generally go ahead and run the defragmenter anyway. Depending on the drive size, this could take several hours to complete, so it’s best left overnight or run when you are away from the PC for a considerable length of time. On isolated occasions, it may be worth running the defragmenter twice, as one run will get rid of the fragmented files, and the second run will pull files together into a lump so that they can be access quicker. This technique could be useful when large sections of data have been deleted, leaving holes in the file structure.

Done!

You have now (hopefully) managed to speed up your Windows XP system: congratulations! I generally tend to run this routine once every month or so to keep the system fresh and running properly. If you’ve got any questions, by all means leave a comment or email me, I’ll try and reply as soon as possible but it may take some time depending on university workload.

Multi-Booting: A Revised Guide - XP/Vista/Linux

Monday, February 4th, 2008

After writing my last quad-boot entry, I’ve gained quite a bit of experience in troubleshooting and sorting out multi-boot installs so I thought I’d re-write my old quad-boot blog to be slightly more like an informative guide rather than a story, and also downgrading it to just cover tri-booting, as I haven’t gotten around to replacing Apple’s OS X Leopard with Sun’s OpenSolaris yet.

Summary

This guide will use Fedora 8 as the Linux distribution, live CDs are available in both Gnome and KDE flavours for those of you who want to try it before actually touching your hard drive’s partition layout. I would recommend installing from the Fedora Install DVD as from experience, the live CD misses out several packages - make and gcc among others - by default that make life a lot easier after installation.

The other operating systems I’ll be dealing with are Windows XP Media Center Edition and Windows Vista Business.

Step One - Partitioning

My desktop PC’s hard drive layout consists of one 200Gb drive for the operating systems and one 320Gb NTFS drive as a central data area, but I’ll assume that you’re dealing with a single drive. Partition whatever space you have into three sections - four if you want a central data area. Although Windows is a lot more space-hungry than Linux, I gave each system an equal amount of space.

You can use whatever tools are available to you to create your partition layout. Both XP and Vista partitions should be NTFS and it’s best to either leave the Linux partition and format this using the install disc. If you’re creating a central data area to use between operating systems, use the FAT32 file system as while Linux can read/write to NTFS, it’s not proven with large file sizes - I use NTFS for my 320Gb data drive purely because FAT32 cannot cope with that size without splitting into separate partitions - something I wanted to avoid.

Step Two - Installing Fedora

Not much instruction is needed at this point. The Fedora Installation Guide is an excellent tutorial through the process. You can install GRUB - the Linux bootloader - to the drive to get the system installed, booting and stable, although booting to Linux will be configured via a GUI utility in Vista later on.

The general guide for creating a swap partition is to use double the amount of RAM you have in your system. My PC has 2Gb of RAM, so I partitioned off 4Gb and set this to be my swap space.

Step Three - Installing Windows

I’ll deal with both Windows systems in the same step here because they’re both relatively similar. You’ll have to do some partition trickery before installation so that Windows assigns the correct drive letters and installs each version in ignorance of anything else on the system.

You can do this via pretty much any partition manager, but I used GParted as included on the Fedora and Ubuntu LiveCDs - or you can use the dedicated 50Mb GParted LiveCD. Select the XP partition, right-click on it and select Manage Flags. Put a tick next to the “hidden” flag and close the window.

Now simply place the XP installation CD in the drive, fire up the installer and install as normal. Just remember to make sure you’re installing to the right partition on your drive. When you’ve installed and can boot to XP, reboot to GParted and swap the “hidden” flags. You can then install Vista as normal.

Step Four - Pulling It All Together

You should now have three working operating systems on your hard drive, but you can only boot to Vista. Head over and download the free EasyBCD program from NeoSmart and install it on Vista. You can then use that to create the necessary boot menu options for each system. EasyBCD includes GRUB and installs it on your Vista partition, so you don’t need GRUB on the Linux partition. Clever eh?

Done!

After you’ve created the boot menu options, reboot into each system once to test. You should now have a working tri-boot system - congratulations! If anything goes wrong or if you’ve got any questions, by all means e-mail me and I’ll do my best to help. If you’re using Fedora as your Linux distribution, head over to the Fedora forums and register.

Hopefully this is more of an informative guide rather than a narrative guide and you’ve found it helpful. If you have (or even if you haven’t), feel free to leave a comment!

Cheers
Craig

Switching to Linux from Windows - Tips from experience

Thursday, January 10th, 2008

In the last few months, I have made the pretty massive jump from being completely Windows-based to being heavily reliant on Linux - the free, open-source alternative operating system. A vast amount of the help and tips I found while in the transition period were found on message forums and blogs, so maybe this will help prospective Linux users decide to switch.

If it ain’t broke, don’t fix it
Don’t switch to Linux “just because”. I had a pretty solid reason to start exploring, but if Windows works for you, then don’t feel pressurised to try Linux. It won’t change your world. It may make your computing experience slightly less stressful, but like 99% of software systems, Linux has bugs - and many of them.

If you’re curious and would like to try it out, get your hands on a LiveCD - there are various Linux distros that can be run from a CD so you can try them before you install, the most popular of which is Ubuntu.

Get used to the command line
Linux has indeed moved on dramatically in recent years to make itself presentable to the (I hate to use the word) “average” user - the person who just wants to surf the web and write letters. That said, while Windows users can often sit in the blissful ignorance that there is such a thing as a command line environment, it’s still very much present in most Linux installations.

Over the six months or so I’ve been running Linux on my laptop, I could not have lived without the command line. Those who have little or no experience with it will either learn or sink. The flip-side of this is that once you have learned a couple of commands, you’ll feel a lot more confident and eventually you will build up experience.

Google is your friend
I also can’t count the number of times I’ve turned to Google with a specific problem and it’s been solved in a matter of seconds with a simple config file edit or command-line instruction. Especially with well-known distros like Ubuntu, support is very easy to find.

Ubuntu is not the only distro out there
Many users refer to Ubuntu in the same was as they refer to Windows - as a complete system. This is completely untrue. Ubuntu is a fairly new entry into the Linux arena and, some say, has only made it to the big-time because of some serious financial clout from a very generous multi-millionaire.

The key to finding a good distro is to research and experiment. You wouldn’t buy a brand new car on just taking a look through a marque list, so why do the same with a computer OS? Ubuntu, for example, didn’t like my laptop’s Intel GMA950 display card, refusing to give me the native 1280×800 resolution, although it detected my Intel 3945ABG wireless card perfectly. Fedora was the exact opposite, but I decided I could work with no wireless for the time being until I found a solution. If in doubt, check the distro’s Hardware Compatibility Lists.

Don’t expect it to work 100% out-of-the-box…
As with the hardware example above, Linux isn’t a “one-size-fits-all” magic system that many Linux fans make out. Personally, my Fedora installation has taken many hours of tweaking and playing with to get it the way I want it - installing media codecs, finding Linux-equivalent software for various tasks, configuring the OS to run the way I want it to.

…But don’t be afraid to play
I haven’t worked with any other distro, but don’t be afraid to get your hands dirty and mess around. If something isn’t how you like it, there’s more than likely a way to alter it. For example, my desktop (screenshot below) has been heavily modified from the standard GNOME desktop layout - the default desktop environment for Fedora and Ubuntu. I’ve made it look the way I want it to look - like Windows - because that’s what I’m used to and I want to use the software because of the functionality, not the look.

Hopefully I’ve given some useful info that’s helped people to decide if they want to switch. I’m quite happily using both Linux and Windows.

My Software
Linux Distro - Fedora 8
Visual Effects Engine - Compiz-Fusion (used to be Beryl on Fedora Core 7)
Window Decorator - Emerald with Crystal-ICE theme

Music - Amarok
Video - VLC & mPlayer
DVDs - Xine
MSN - aMSN (Alvaro’s Messenger)
Email - Mozilla Thunderbird
Web - Mozilla Firefox
FTP - gFTP (standalone) & FireFTP (Firefox extension)
Office suite - OpenOffice
BitTorrent - Azureus
Graphics - Adobe Fireworks CS3 (running under Wine)
Text Editor - Gedit

The Quad-Boot Saga: Background

Thursday, July 5th, 2007

In this post I’ll try and go into as much detail as possible about how I managed to get my Acer 5630 to boot four operating systems. I’ll first give a bit of an overview as to why I chose to install them all. I must point out that I was doing almost all of this flying blind and troubleshooting problems as they arose.

First off I have always been a Windows user since Windows 95 although I’ve really only been seriously playing with it since Windows 2000 and XP. I guess the main motivation for quad-booting was to dispell any opinions that I was a Microsoft “fan-boy” (however much I despise the word) and I was open minded about other systems.

Windows Vista was the first operating system I decided on, as it was what I was using when it was a single-operating system machine. I then stumbled across the gold-mine that is the OSx86 Project and InsanelyMac. For a while I had been using the Apple OS X system for recording, and was fairly comfortable with using it - this made it the ideal choice for a second system.

When I had settled on the idea of dual-booting, I thought about tri-booting as a way of learning more about the UNIX/Linux family - because although OS X is heavily based on UNIX under the bonnet, I still wanted to gain a bit of confidence on the command line and experience Linux as it is. I originally chose Ubuntu as the Linux distro to install, but after trying and failing to get GRUB - the Linux bootloader - to play nicely I chose Fedora Core 7 (the GRUB issue was nothing to do with Ubuntu I later found).

So that left me with three operating systems. After setting them all up and getting them all to play nicely, I thought “why not add a fourth?” - in the typical techie way. It would be nice to have a fall-back Windows system just in case Vista couldn’t handle one program because of incompatability (it wouldn’t be the first time either) - and my Acer actually has a Windows XP Media Center 2005 licence sticker on the bottom not being used, so this became the last piece in the operating system jigsaw.

Next came actually building the thing…..

The Quad-Boot Saga: Stage 1 - Vista & Linux

Thursday, July 5th, 2007

After I’d decided which operating systems to install, it was time to get to the dirty work of actually installing them. Seeing as I had dual-booted Windows Vista and Mac OS X before using the Vista bootloader I decided to use this method again for the quad-boot.

A quick run through the major specs of the laptop:
Processor: Intel Core 2 Duo T5500 (2 x 1.66Ghz, 2Mb L2 cache)
Memory: 1Gb DDR2
Hard Drive: Western Digital 120Gb (111.79Gb formatted)

So Vista was installed without any memorable trouble, I gave it a 30Gb NTFS partition because Vista has a reputation for being resource-hungry. Then the fun started - I installed Fedora perfectly onto 15Gb, partitioning it using Fedora’s own installer. I ignored the need for a swap partition because I was going to be short on drive space and I wasn’t planning on using Fedora as the main OS on the laptop.

Getting GRUB to work properly proved to be my first learning curve. Where OS X had simply installed its bootloader on its partition and set it to be active, Fedora installed it onto the bootsector of the hard drive. Through Google I managed to find the commands to enter at the Repair prompt on the Vista installation DVD to re-write Vista’s bootsector:

bootrec /fixboot

bootrec /fixmbr

I then booted to the Ubuntu LiveCD that I had downloaded when I planned on installing Ubuntu. At the terminal, I entered:

sudo grub

find /boot/grub/stage1

I was given the partition number where Linux was installed and therefore where I had to reinstall the GRUB bootloader:

root (hd0,1)

setup (hd0,1)

I then had GRUB setup on the bootsector of the partition and not the drive. I later discovered that this could be done through one of the advanced menus on the Fedora installer. Oh well, live and learn :).

Entering quit then returned me to the main command prompt, where I then had to take a disk-dump of the bootsector so I could feed it into the Vista bootloader:

sudo fdisk -l

sudo dd if=/dev/sda2 of=/linux.bin bs=512 count=1

The first command lists all of the partitions on the disk so I can see how Linux labelled them. The second command actually took the first 512 bytes (i.e. the first sector) of the partition and dumped it inside a file on the root drive called “linux.bin”. I then transferred this to my USB memory stick to put onto Vista.

Once I had my copy of GRUB dumped into a file, I booted into Vista and fired a command prompt. The “boot.ini” method has been changed to a command-line based bootloader, so if you’re confident with the command line you’re ok. If not, download EasyBCD from NeoSmart. Assuming you have called the file “linux.bin” and it’s in the root C:\ drive:

bcdedit /create /d “Fedora Core 7 - Linux” /application BOOTSECTOR

That will give you a long identifier string to use with the rest of these commands - in place of {YOUR-ID-HERE}:

bcdedit /set {YOUR-ID-HERE} device partition=C:

bcdedit /set {YOUR-ID-HERE} path \linux.bin

bcdedit /displayorder {YOUR-ID-HERE} /addlast

After that, I rebooted and I had a lovely dual-boot setup with Linux and Vista :D.

The Quad-Boot Saga: Stage 2 - OS X and Media Center 2005

Thursday, July 5th, 2007

This was the slightly easier bit. Once I had Vista and Fedora happily coexisting, I added OS X. Before I continue, I would like to point out that I am writing this for educational purposes only and in no way do I take responsibility for any actions taken by visitors to this site :).

With that little bit out of the way,I had installed and re-installed OS X more times than I can care to remember during the dual-boot phase with the same laptop, trying various different kexts and solutions to get things like the audio and ethernet working. I used this guide to install OS X and used the JaS 10.4.8 install disc.

OS X installation went as smoothly as it could, I did experince some kernel panics during boot at one point, I’m not sure exactly what was wrong but a reinstall solved the problems. After following the instructions in the guide to add OS X to the Vista boot menu, I had a fully functioning tri-boot system :).

This is where the major problem occurred. Due to the fact that the system I was attempting to quad-boot was a laptop, it only had one hard drive. I found that the partition table of any hard drive can only have four entries - meaning that my initial plan of having one partition per operating system and one FAT32 partition for music and documents (FAT32 is the only filesystem that can be reliably used by all three platforms) wasn’t going to work - unless I could convert one or more of the current partitions into a logical volume.

With quite a bit of research on Google and various message forums, I converted both OS X and Fedora to logical partitions using Acronis Disk Director on Hiren’s BootCD - that CD has been an absolute God-send for me, the amount of utilities that are included with it is astounding. After converting the partitions and creating the last two to be used for XP and data storage, a had a configuration which looked like this:

Vista - 30Gb NTFS (primary)
Fedora - 18Gb ext3 (logical)
OS X - 26Gb Mac OS Journalled (logical)
Media Center - 8Gb NTFS (primary)
Data Storage
- 28Gb FAT32 (primary)

I know this isn’t the ideal configuration (three logical partitions sandwiched between two primary) but as I said in the introduction post, I was doing this as I was going along and using it as a learning experience :P.

Then came the Media Center install, that went pretty smoothly as well (to be honest the only OS that didn’t was Ubuntu - and that was GRUB’s fault), although before I ran the install I had to do a bit of partition hiding using GParted on the Ubuntu LiveCD. This is because without hiding the other NTFS and FAT32 partitions on the drive, the Media Center install will automatically copy the related boot files to the first readable partition it finds on the drive - and also set drive letters accordingly.

So I booted to the Ubuntu LiveCD, fired up GParted and set the “hidden” flags on the Vista and Data Storage partitions, and also set the Media Center partition as “boot”. After that, I ran the Media Center install without a problem, and booted into it a few times to check that all was well. I then booted back into GParted, removed the “hidden” flags and set the Vista partition as “boot” again.
The last thing left to do was add the entry into Vista’s bootloader. I had to copy three files to the C:\ drive from the XP installation drive - ntdlr, boot.ini and ntdetect.com. Once these were all in place, I created a new Legacy Bootloader using EasyBCD - I was getting lazy at this point - and rebooted with fingers crossed.

And that’s about it. It has been one hell of learning experience for me, and I hope that this series of blogs are of use to some people out there.

Thanks for reading!