Latest Publications

Life and Blogging is Hard

Plus.net have moved to the new CGI platform after some sort of disaster. As this was coming for almost a year, I’m shocked that the platform still seems in such a shoddy state.

This has meant that the site has been misbehaving for a few weeks. Most notably causing random Apache errors.

I think that it’s a wake up call to me that I need to get this blog living somewhere else. Letting it expand and breathe as it needs to.

Some of the way to that is getting a new hosting plan sorted out. I wanted to do this in an el-cheapo style by using SQLite instead of mySQL to power WordPress, but it seems like the database abstraction that it uses might as well be non-existant. mySQL or bust I’m afraid.

In a time when PHP provides a unified access library, and many frameworks have a respectable set of DB abstraction libraries – it’s frustrating to see the WordPress team get suckered into making new features the top of the development priority list, while failing to solidify or revisit programming fundamentals.

And what’s the point of having plugins at all if they don’t get approved in any way? After my trial with SQLite, I’m genuinely worried about any WP plugins now.

Moving soon folks!

How To Install Windows XP From the Hard Disk Drive

Installing Windows XP / 2003 from the hard disk drive is a bit of a bind, and I have had to do it a few times when there is no CD drive available.

To get it going – you need to have command line access to the target computer. In a situation where there is no CD drive, you can use WDS and a Windows RE WIM. I’ll not go into that right now, but here’s the command to copy the files to your target drive and install Windows onto it.

winnt32.exe /tempdrive:C: /syspart:C: /makelocalsource

Windows will start the first stage of the setup, and then will require a reboot. If setup carries on – then it was successful!

Quick Tagging and Renaming

Last week I recovered a friend’s mp3 library from a 2nd generation iPod. All was well except for that fact that any music put onto the iPod is given a random file name such as C00XY.mp3. Not helpful.

After scratching my head and thinking that we would have to rename most of the files manually, I started to look for re-tagging programs. A few were recommended on the internet but I found them to be too unwieldy or didn’t quite work right.

Thankfully, I discovered a lightweight tagging application called Ex Falso. A fairly simple to use tool which easily re-tags your music, or renames the files with much more ease than any others that I have come across. It only took a few minutes to read the tags of around 3500 songs and rename them all.

To install in Ubuntu, simply run the command:

sudo apt-get install exfalso

As an added bonus – it also fixed tags of .m4a audio files, meaning that preparing music to go on my iPod Touch in Linux is slightly easier. Wehey!

Getting the HP 2400c Scanner working in Linux Ubuntu Karmic

I had a tough day working on Ubuntu to get a HP 2400c Scanner working today.

A list of problems included the drivers not being included in the Sane package – and after an upgrade to karmic a normal user couldn’t access the USB device.

Here’s a quick rundown of what I did to get it working.

1 – Download the HP scanner drivers from Elcot
2 – Install the drivers as root. The instructions are in the readme file.
3 – Create a new udev rule by creating the file /lib/udev/rules.d/71-scanner.rules
4 – In the rules file, paste in the following code:

#HP ScanJet 2400c
ACTION=="add", ATTRS{idVendor}=="03f0", ATTRS{idProduct}=="0a01", GROUP="scanner"

5 – Add the user to the scanners group.
6 – Run Sane or Xsane and be happy!

There was a bit of groping around as I hadn’t created my own udev file before without following the instructions or howtos for specific hardware.

The key point to know is that there are some very useful commands:
lsusb – lists info about the usb devices plugged in
udevadm monitor – outputs udev events and shows you the device paths for any devices plugged in / removed
udevadm info –query=all –path /devpath – Shows the udev properties of a specific device
udevadm info –attribute-walk –path /devpath – Shows the udev properties of a device and its parents
* devpath is the path output from udevadm monitor

Once I’d worked my head around these, I could put together the .rules file that I needed. This basically checks the vendor and device ID match, and that it is an ‘ADD’ action. Once confirmed, udev adds the group membership of the device to ‘scanner’ so that the users you want to use the scanner can actually use it!

Hurrah!

Prevent Windows from Reinstalling Group Policy Programs

While Group Policy software distribution is a quick and easy way to get software around a network, it isn’t without its problems. One such problem is when a computer is attached to a new domain. If your software distribution is the same, Windows will still reinstall the MSI packages.

The simplest way is to join export a registry key from a computer that is currently joined to the new domain, and then import it into the new system.

And here it is:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Group Policy\AppMgmt

Simple Linux DHCP / DNS Server

I’ve just completed the first DNS and DHCP server that I’ve built for a while. This was using Ubuntu Linux 8.04.

The nice thing about the process this time around as opposed to when I set one up a couple of years ago is that I was a little more au fait with the process. The DHCP successfully updated the DNS records, and everything ticked along nicely.

It’s going into production tomorrow, so I’m hopeful that it will fix a number of network problems that a client has been having with the RM DHCP Server service that runs in Windows XP.

If it would be easy to tie the upcoming Samba 4 into the mix, then I think that you have the perfect open source server! I have another server to put together soon, so I plan to write a ‘howto’ and post it here.