Upgrading to Ubuntu 7.10 (Gutsy Gibbon)

Ubuntu Logo
Recently I installed Ubuntu 7.04 on my computer and have enjoyed it very much. I discovered a new release was made 7.10, named the Gusty Gibbon. It turns out the version numbering scheme Ubuntu uses is the year (07) and the month (10) of the release. That makes a lot of sense to me. How often have you looked at downloading software only to find it has not been updated in years?

I mainly use my system for software development, so I had not made many modifications to the original installation beyond installing Java, NetBeans, various Java libraries, etc. Ubuntu provided an upgrade option that, instead of downloading an ISO image, burning a CD, etc., I just clicked an button in the Update Manager that said update. It seemed too good to be true, but (after backing up my system) I gave it a try. For the curious, they provide instructions on doing the upgrade and cautions that you can only do this if you have version 7.04.

The process went very smoothly. The upgrade wizard warned me that several packages I had installed were no longer supported and could be removed. One of those packages was Emacs, which I’ve used for decades. I decided to let the system remove it as I could reinstall it later. It turns out that the install wizard later installed a newer version for me. It would have been nice if they had reworded those warnings to say that newer versions would be installed as opposed simply removing the existing ones.

As the update process continued, I was asked if I wanted to keep or replace various configuration files (I chose to replace them as I had done very little customization). After downloading and installing over 1300 files, the system rebooted and all appears to be working fine.

This version of Ubuntu includes the capability to write to the NTFS (Windows) file system. This is pretty handy (for me) as I am currently dual booting to access certain applications available only in Windows. There are various other improvements you can read about on Ubutntu’s web site.

Grails 0.6 checkBox Tag Workaround

A bug was introduced in Grails 0.6 that incorrectly handles boolean properties in views. The Grails generate-all command will generate the controller and views for your domain class. If you have a boolean properties, the GSP tag checkBox will be used to render that property in the various views. The bug introduced will not correctly handle passing the value of the checkBox back to the controller.

A fix has already been published on the Grails site. However, if you don’t want to switch to the Grails 1.0 RC yet and don’t want to rebuild Grails from source, there is an easy workaround. You can create an application taglib and inserted the corrected checkBox code there. Your application taglib will take precedence over the broken one. You also see a warning will running your application. Hopefully this will be your reminder to remove it after upgrading to the next version of Grails.

Create a groovy file whose name ends with TagLib.groovy and place it in /taglib. Below is the contents of mine (again taken from the Grails web site).

class AppTagLib {

    /**
     * checkBox tag fix for 0.6 value bug
     */
     def checkBox = { attrs ->
           def value = attrs.remove('value')
           if (!value) value = "true"
           def test = attrs.remove('test')
           def name = attrs.remove('name')
           out << '<input type="hidden" '
           out << "name=\"_${name}\" />"
           out << '<input type="checkbox" '
           out << "name=\"${name}\" "
           if(test) {
                 out << 'checked="checked" '
           }
           out << "value=\"${value}\" "
           // process remaining attributes
           outputAttributes(attrs)
         // close the tag, with no body
         out << ' />'
     }

    /**
     * Dump out attributes in HTML compliant fashion
     */
    void outputAttributes(attrs)
    {
        attrs.remove( 'tagName') // Just in case one is left
        attrs.each { k,v ->
            out << k << "=\"" << v.encodeAsHTML() << "\" "
        }
    }

}

Missing or corrupt HAL.DLL after installing Ubuntu

Recently I decided to install, in a dual boot configuration, Ubuntu 7.04 on my computer running Windows XP. Some documentation I read said that the Ubuntu installation process will discover and use free space on the disk. I decided to try that approach.

I purchased PartitionMagic online to resize my main partition so there would be room for Ubuntu. My computer, an HP desktop, had a recovery partition already as drive H under Windows. I moved a large number of files from the C drive to a USB drive and resized the C partition to leave about 70 GB free for playing with Linux.

The install process for Ubuntu went without a hitch. I had installed Linux before over the years, but this time I had different peripherals (e.g., USB drives, HP All-in-one, UPS, etc.) that I didn’t expect to be recognized. As far as I can tell so far, everything was recognized and configured properly.

However, when I tried rebooting into Windows, I got a message about a missing or corrupt HAL.DLL. The only option at that point was to reboot again. From some brief research on the Internet, it seems this must happen a lot and not just from Linux installs. There is an article from last year in InformationWeek that addresses the issue.

In my case, the rebuild did not work. Typing “help” in the recovery console, I found the DISKPART command. Running this without arguments lists the partitions on the current drive. My main C drive was listed as partition 3. The partition number referenced in BOOT.INI was 2. Changing BOOT.INI to reference partition 3 was the fix, but I could not find an editor in the recovery console. I ended up editing a BOOT.INI on another computer, burning that onto a CD and replacing the bad one on my HP with the one from the CD.

Finally, I can boot into Windows and everything appears to be working fine in both Linux and Windows. I plan to use Windows for a couple of applications like Quicken, but Linux for everything else. Hopefully this post will help others.