Gnuru.org
Productive Linux


Subscribe

 Subscribe via Feedburner in a reader

Enter your email address:

Delivered by FeedBurner


Login
Login:
Password:



Don't have an account?
Sign up to Gnuru.org
Forgot your password?

IBM Thinkpad T23 Installation
17 July 2005 @ 15:44 BST
by Paul

Update: Using Debian Unstable can be a bit like living dangeously. A couple of days ago, an attempt to install inkscape, resulted in my kernel being removed. Along with pcmcia-cs and ndiswrapper. I installed kernel 2.6.11, but this involved reinstalling ndiswrapper. See below.

Reasons for the reinstall

The hard disk on my T23 had started to report errors. I knew it was dying and I needed to swap it out.

The original disk was a Hitachi/IBM 15 GB. I bought a Samsung 40 GB disk as a replacement.

Swapping the hard disk

Instructions on IBM's web site show you how to swap hard disks. They even have a movie. The movie and the instructions both stop just after the hard disk and tray are pulled out of th laptop.

What IBM's instructions don't tell you is that you need to get the drive out of its caddy. It was fixed there with four screws that would not budge. After several hours, of trying and buying a brand new set of screw drivers, in frustration I decided to apply liberal amounts of WD40. I don't know whether WD40 is compatible with hard drives (I didn't really want to mess the hard drive any more than it was just in case I needed to use it for anything), but I eventually got the screws out and removed the old drive. I wiped all the WD40 off the caddy and fitted in the new drive. So far so frustrating.

That was hard...now comes the harder part.

The Nightmare Partitioning Problem

The fist thing I did was to boot with the Knoppix CD and repartition the hard disk with GNU parted. Having done this, I halted Knoppix.

The next task was to reinstall Windows 2000. This has to be done from IBM's product recovery CDs. These don't ship with the computer so you have to ring up IBM to get them sent to you.

The installer gave me an error about disk geometry, but I clicked OK and it proceeded OK. Or so I thought.

However, when I tried to boot into Windows, I got an error regarding the NTLDR. Bascially, Windows couldn't find itself.

Fortunately, I could still boot into the product recover partition that IBM puts on the laptop. This asks you to put in recovery diskettes. Of course, I didn't have those, I had a recovery CD. So, then you have to go and create your recovery diskettes.

Once I'd created the recovery diskettes I put them in the laptop. Result: they wiped the partition table. Brilliant.

Back to Knoppix. Rebooted. Partitioned the hard disk once again.

This time I paid more attention to the Windows 2000 installer messages. These complained that the disk hadn't been partitioned properly and that the disk geometry was 5174 cylinders, 240 heads and 63 sectors. When I booted back into Knoppix parted was convinced it was 4870 cylinders and 255 heads. Modern disks, of course, aren't concerned with this and will comply with whatever geometry you deem it to have. Windows 2000 is at fault here, because it didn't allow me to partition the disk as I wanted, but it went ahead and installed itself anyway.

It was also GNU parted that was at fault. Windows 2000, fdisk and cfdisk all reported the same geometry, only parted was on its own. There was no way of forcing parted to assume the same disk geometry as the other programs.

I had to ensure that the data on the windows partition was OK, because reinstalling Windows 2000 would wipe my partition table.

So, the problems were a) Windows 2000 had to be installed first, otherwise it would wipe my partition table, b) therefore I needed a partitioning utility that would save the Windows 2000 data. c) GNU parted, however, insisted that disk geometry was different from what the BIOS thought and there was no way of overriding parted's assumptions.

There was only one solution, one that I had long resisted. I was going to have to shell out for Partition Magic. This made me $82 (including VAT) poorer, and Symantec $69.99 richer. This is extraordinarily expensive for a program that only partitions a hard disk, but it is the best product on the market and Symantec knows it.

It worked like a dream. (Symantec doesn't offer it as a self-extracting zip, only as a zip. This meant I had to download an extracting utility with my newly installed Windows 2000. I suppose they assume that if you want to partition a hard disk you should understand how to extract a zip archive.)

After that it was easy. I ran the Debian net install CD, mounted the partitions I had created in Parition Magic, loaded the ethernet module and I was away.

I checked that I could boot into Windows 2000 and then into Linux. Yep - both worked fine.

Installing Debian

I didn't do tasksel, but installed the base system. When that had finished, I edited /etc/apt/sources.list for 'sid' rather than 'stable'. I then did:

	   apt-get update
	   apt-get dist-upgrade

Sound

I tried installing the ALSA modules and chose snd-intel8x0. This works unless you do a suspend-resume cycle. Sound stops working. Doing

  alsactl power off
  alsactl power on

is necessary to get it working.

X Windows

The laptop has a built in LCD screen, SuperSavage server works out of the box.

WLAN under kernel 2.6.11

Update: since upgrading to the 2.6.11 kernel, I needed to upgrade ndiswrapper.

For 2.6.11 the core debian package wasn't installing. Compiling it from the Debian sources wasn't working either, because of dependency issues. I had to go to download an original from here. I then compiled it like this:

cd /usr/src
tar jxvf ndiswrapper-source.tar.bz2
cd modules/ndiswrapper
fakeroot debian/rules binary-modules
fakeroot debian/rules binary-utils
cd ..
dpkg -i ndiswrapper.deb

The drivers that were running under 2.4 no longer worked. A list of drivers is here and the one I needed I got from here.

WLAN under 2.4.27

This particular T23 doesn't have built-in WiFi so I bought a Netgear WG511.

I installed kernel 2.6.9 and used modconf to install the prism54 modules. This produced the error:

	  prism54: request_firmware() failed for 'isl3890'
	  eth1: could not upload firmware('isl3890')

The problem is that I have the wrong sort of card, some WG511's are made in Taiwan and some are made in China. The Taiwanese maufactured ones work (according to my extensive googling on the subject), the Chinese ones don't. I had a Chinese one. The solution was to use ndiswrapper and the Windows 2000 drivers.

This creates its own problems as after a suspend/resume cycle it will often crash. To prevent the crash this is required:

	cardctl eject
        modprobe -r ndiswrapper

On resume either insert the card or type:

 cardctl insert 

and do:

 modprobe ndiswrapper

If you are using encryption then this has to be configure. In Debian, it is possible to configure it in /etc/network/interfaces

Suspend/Resume under 2.6.11

Since upgrading kernels using ACPI for suspend/resume is much better. There are no longer any hangs when a card is inserted in the PCMCIA slot. Ndiswrapper is properly handled.

You must install the thinkpad buttons: apt-get install tpb

You also need the proper scripts, see [ACPI Thinkpad Scripts].

Hibernate under 2.6.11

I haven't tried hibernate as it involves patching a kernel. The patch won't take if you have the Debian sources. If anyone has an easy work around for this please let me know.

Suspend/Resume (under 2.4.27)

Suspend resume works as long as the kernel has the apm modules compiled in. The more advanced ACPI wasn't working. I thought because the BIOS wasn't compliant, but it is. Hibernate, i.e. saving the system state to disk, doesn't work. Because of these issues I found it easier to use the 2.4.27 kernel.

Internal Modem

The internal modem is an evil WinModem. It works with the right LTModem package: http://www.physcip.uni-stuttgart.de/heby/ltmodem/

As long as I use a stock Debian kernel, the packages here work straightaway:http://www.physcip.uni-stuttgart.de/heby/ltmodem/dists/debian/8.31a8/




Comments disabled