SuSE Linux 7.2 on an IBM ThinkPad 240x

This page provides a brief guide to installing SuSE Linux on an IBM ThinkPad 240x. The short version is: It all works pretty well. There are not too many hurdles, and you end up with an excellent sub-notebook running an excellent distribution of Linux.

This page was inspired by these notes on the 240x written by Ross Miller. I found his notes to be an invaluable guide while I was fumbling around trying to get all of the ThinkPad's features to work.

First a little about my choice of hardware and software.

IBM ThinkPad 240x

Weighs only 1.5kg (3lb). I think that this is mainly due to the lack of a CD-ROM drive. Very good battery life of c. 4 hours (supposedly!). It's got a fast Pentium III chip running at 500MHz - that's the same as my desktop! And it's cheap - I got mine on Tottenham Court Road in London for £599 + VAT.

Just as important, it looks really good. I was on the verge of buying an iMac. They have a very impressive set of features for the price, and Hilde would be much happier with a Macintosh. However, the new iMac is just ugly - all white and plastic. We decided that it looked like a tupperware box! The IBM is tiny and thin, with a nice metallic black sheen on the top cover.

My ThinkPad came with only 64Mb of memory, which is frankly insufficient. I've since upgraded to 128Mb for only £10. The extra performance is well worth the small expense. Memory is so cheap these days that I advise anybody to buy as much as their PC will take.

SuSE Linux 7.2

I've always used SuSE Linux on my desktops, so it was an obvious choice for this notebook. Unfortunately SuSE 7.0 only comes with XFree86 v4.00, which doesn't support the ThinkPad 240x's video drivers. So, I had to buy a new distro... and yet again SuSE seemed to have the best value for money. I purchased SuSE Linux 7.2 from PC World <cringe> for £50.

3Com 10/100 Ethernet Cardbus PC Card

You need a network card in order to install software, since the ThinkPad comes without a CD-rom drive. (I suppose that you could buy the separate CD drive - but I've no need for a CD drive and didn't want to purchase one just for the purpose of installing the software.)

Initially I bought a Psion/Dacom LANGLOBAL 10/100 Ethernet PC card. Don't do this! This Psion card is not supported. (Doh!)

I found some good testimonials about 3Com PC cards on the web, and I carefully checked that the one I was buying was on the list of supported cards. The one I bought was a 'Dell' branded "3CCFE575CT". It works beautifully, and even comes with its own short Ethernet cable.

Installation

The most obvious barrier to installation was the lack of a CD-rom drive. My solution was to install via NFS. I have a desktop PC with a DVD drive running Linux, so I simply shared the SuSE 7.2 DVD across the network, and used the "NFS" installation option. The fact that the entire distribution fits onto one DVD makes the installation very easy. The alternative would be to swaps CDs in and out of the drive, mounting and un-mounting them.

If you have a desktop PC running windows, I suppose that you could start up the windows FTP server and do the installation via FTP. I don't imagine that you'd run into any problems.

Details: To share the SuSE Linux 7.2 DVD via NFS.
  1. Add the mount point into the /etc/exports file. On SuSE, the mount point for the CD drive is "/cdrom", so add the line "/cdrom (ro)" to the /etc/exports file.
  2. Insert the SuSE Linux 7.2 DVD into the drive.
  3. Mount the DVD with the command "mount /cdrom". Remember, your mount point might be different if your desktop isn't running SuSE Linux. It's important to do this before you start the NFS server. I ran into trouble if I did it the other way around.
  4. Start the NFS server. On SuSE Linux, this means editing the file /etc/rc.config to set the variable NFS_SERVER="yes", and entering the command "/etc/rc.d/nfsserver start" as root.

Now you're ready to begin the actual installation. Attach the floppy disk drive to your ThinkPad 240x and insert the SuSE Linux 7.2 boot disk. Start the machine and select "SVGA" graphical installation.

The SuSE installer automatically detects your PCMCIA chipset and asks for the Modules disk to be inserted. Follow the instructions, and the installer will read from the disk and then pop-up a red dialogue that states that the installation CD cannot be found. Press <return> to proceed. Select your language and keyboard map, and you should be at the Main Menu.

Before you start the installation, insert your Ethernet PC card into the slot. You should hear two high-pitched beeps, which tells you that the PCMCIA driver has detected the card and installed the appropriate driver - magic! Eject the floppy disk - you don't need it any more.

Next, begin the installation process:
Select the menu option Start installation / system, and press <return>.
Select the menu option Start installation/update, and press <return>.
Select the menu option Network (NFS), and press <return>.

The installer now asks you to configure your network connection. I chose No to Automatic configuration via bootp? and entered IP addresses manually. After a while, you are presented with a choice between YaST1 and YaST2 installation - choose YaST2 for the prettier of the two installers.

The graphical installer now starts up and you can proceed as normal. There are just a couple of things worth pointing out...

Make a Hibernation Partition during Installation

The ThinkPad has the capability to write its memory state to the hard-disk and turn itself off. This enables you to avoid rebooting the machine every time you want to turn it off. Great! To enable this function you need a small partition on the hard-disk. So when you get to the screen Preparing Hard Disk - Step 1, select the second option Custom partitioning - for experts.

Make the following partitions on the Hard Disk: (This is my actual configuration for my 11.2 GB disk.)

Device Start End Size F Type Mount
/hda 0 1466 11.2 GB   IBM-DARA-212000  
/hda1 0 2 23.5 MB F Linux native (ext2) /boot
/hda2 3 19 133.3 MB F Linux swap swap
/hda3 20 1442 10.9 GB F Linux native (ext2) /
/hda4 1443 1466 188.2 MB   IBM Thinkpad  

First delete all of the existing partitions and then create four new primary partitions. Refer to the Reference Manual for instructions on how large to make these. In a nutshell, the /boot partition need only be tiny, but it should be first. The swap partition should be at least 128 MB.

Make the IBM Thinkpad partition by selecting Create --> Primary Partition to get the usual partition definition screen. Select the Do not format radio button, and manually type 0xA0 into the Filesystem ID: field. The hibernation partition should be as big as "your system memory plus your video memory plus 2 MB". If you plan to buy more memory, then make space for it now - I've allowed a generous 188 MB. Before you can use this partition, it needs to be formatted with the lphdisk utility - do this as soon as the OS installation is complete.

Don't use ReiserFS

The root '/' partition should contain the balance of the disk's space. You'll note that I've formatted it with the "traditional" Linux filesystem - Ext2. There are two very good reasons not to use SuSE's "filesystem for the next generation" - ReiserFS:

  1. ReiserFS bypasses the kernel's normal filesystem flushing mechanism. This makes it impossible to use noflushd to spin down your hard disk when it's not in use. In short, ReiserFS will run your battery down more quickly that the alternative.
  2. I initially used ReiserFS. This first attempt worked for a few hours, and then failed catastrophically - the filesystem wouldn't allow any files to be written, and the kernel couldn't get to the swap file. I reinstalled the whole system without ReiserFS, and the problems have not recurred. Why? I'm guessing that it didn't interact well with the laptop's suspend functionality - but that's only a guess.

Extra packages

When you get to Software Selection choose a basic software package (the default is Default system with Office, which works fine for me), and the click on Detailed selection... --> Select single packages.... This takes you to a screen which allows to to select individual RPMs to install as well as the default set.

You will need...

lphdisk in order to format your hibernation partition. Find it in group Utilities/System.

noflushd enables your hard disk to spin down when its not in use. This is important if you want to maximize your battery life. Find it in group System Environment/Daemons.

nedit is an excellent editor, made especially for people like me who hate both vi and emacs! You don't really need it, but I thought it was worth plugging it here. Find it in group Applications/Editors.

wmakerconf allows you to configure WindowMaker, my recommended window manager. Find it in group X11/Window Managers.

X Server. (First Boot Up during Installation)

The video controller is a Silicon Motion LynxEM+. You need at least XFree86 v4.02 for native support of this controller. Don't bother trying with XFree86 v3.3 - it interacts very badly with the stand-by functions.

After you've waited for a very long time, the installation of packages will come to an end, and the installer will boot up your new system for the first time. It immediately goes into some basic configuration screens, one of which is X Server configuration.

My first glitch hit me here. Whatever display I selected, the screen would just go blank. The hard drive would churn for a few seconds and nothing further would happen.

After a little bit of playing around I discovered that the glitch isn't very serious. Just select the screen type (I selected VESA 800x600 at 75Hz, I'm sure the LCD 800x600 or even the IBM ThinkPad would be equally good choices) and then press <return> a few times until you get the test screen. Select Abort to get back to the display setup screen. The only change I made was to increase the screen depth from 8 to 16-bit. Then test and save the configuration.

The SuSE setup program correctly identifies the video driver chipset and selects the correct XFree86v4 module (siliconmotion). I've not had to change the setup since. The SuSE default even selects middle mouse button emulation, so that you can middle-click by pressing down both mouse buttons at the same time.

Ross Miller has reported some screen redraw problems with Netscape. I get this with Netscape and some other apps too (konsole). It doesn't seem to cause any real inconvenience, but it would be nice to know how to solve it.

Sound (Cirrus Logic CS4281)

My initial installation failed to install the sound configuration package for YaST2. I'm pretty sure that this is a problem with my DVD, rather than a general problem. Installing this package from the CD #1 worked with no problems.

Just start up YaST2 (command yast2) and select Hardware --> Sound. Follow the normal installation procedure, and the ALSA sound drivers are smoothly installed. My only comment is that you have to turn the volume up quite high in order to hear the test sound at all.

Advanced Power Management (APM)

The first thing to do here is to format the hibernation partition you created during the initial installation. Just log in as root and type the command lphdisk. That's it!

The next thing to do to reboot your machine and enter the IBM BIOS Setup Utility by pressing the <F1> key. You need to activate the hibernation function from here. Select Config --> Advanced Setup --> Power. Make sure that the following values are set:

  • Suspend when LCD is closed = [Suspend].
  • RediSafe = [Enabled] (works for me).
  • Screen Blanking = [Disabled] (this should only be enabled during presentations, where you don't want the automatic "screensaver" to kick-in. It was enabled on my machine when I bought it).
  • Suspend to hibernation = [30 Minutes] (this is the setting that automatically hibernates your machine after it's been suspended for a while.I've chosen the shortest possible delay, hopefully that should improve my battery life).
  • CPU Speed = [Auto Medium] (my system came with this set to "Fixed Maximum". I turned it down, and haven't noticed any performance hit.)

Finally, reboot your machine, log in as root and activate the APM daemon:

  1. Edit the file /etc/rc.config to set the variable START_APMD="yes".
  2. Edit the file /etc/rc.config.d/apmd.rc.config to set the variables APMD_ADJUST_DISK_PERF="yes", APMD_PCMCIA_SUSPEND_ON_SUSPEND="yes" and APMD_STOP_SOUND_BEFORE_SUSPEND="alsa". This last entry seems to be needed - without it the sound stops working after a suspend-resume.
  3. Start the APM daemon by entering the command "/etc/rc.d/apmd start" as root. (If it's already going then try restart instead.)

Enable "noflushd"

The noflushd program runs in the background and spins downs your hard disk when it's not being used. This saves power and improves your battery life. Again, you need to be logged in as root:

  1. Edit the file /etc/rc.config to set the variable START_NOFLUSHD="yes".
  2. Edit the file /etc/rc.config.d/noflushd.rc.config to set the variable NOFLUSHD_TIMEOUT=2. This sets the disk to spin down after two minutes of inactivity - you might prefer a longer wait... 5 minutes?
  3. Start the noflushd daemon by entering the command "/etc/rc.d/noflushd start" as root. (It will also start automatically each time you boot up.)

Won't suspend with NFS filesystems mounted

I frequently connect to NFS filesystems from my laptop, and I couldn't work out why it sometimes failed to go into suspend properly. The log file /var/log/messages contained the following tell-tale sign:

kernel: nfs: server <host_name> not responding, still trying

It's fairly obvious that the suspend fails because it can't shut down the NFS client. The solution is to make sure you always 'soft' mount NFS filesystems. This ensures that the connection is able to time out. It may take a minute or so, but the suspend does eventually succeed. Mount your NFS filesystems with a command like this: "mount -o soft /mountpoint", or include the soft option in the appropriate line in /etc/fstab.

Infrared (IrDA)

I have a Nokia phone with a built in modem, accessible via infrared. I like to use wvdial to dial out. The IrDA port worked perfectly and without needing any configuration.

I just added the following dialler to my /etc/wvdial.conf file:

[Dialer mobile]
Baud = 9600
Modem = /dev/ircomm0

You need to activate the IrDA before dialling with the command "rcirda start".Then "wvdial mobile" establishes the connection. When you are finished be sure to shut down the IrDA with "rcirda stop" - having the port active at all times wastes the battery.

Modem (Lucent Microelectronics WinModem 56k)

Again, this works amazingly easily. You need to download the driver, but it's available as an RPM specifically for the SuSE distribution. You want the file called ltmodem-kv_2.4.4_4GB-5.99b-1.i386.rpm - Make sure that the RPM name matches your kernel. To discover your kernel version look at the first line of output from the dmesg command.

Install the RPM using YaST (or the rpm command) and that's it. The RPM points /dev/modem to the correct device.

Universal Serial Bus (USB)

The USB drivers work perfectly, as far as I have been able to test them. The drivers didn't load correctly on the very first boot up - but subsequent boots seemed to be fine.

I have a USB mass storage device. To use it I simply install the driver with "modprode usb-storage" and then mount it as though it were a SCSI disk... "mount -t auto /dev/sda1 /mountpoint".

RC_LANG

This environment variable is set in the file /etc/rc.config. Initially the SuSE installer get it to en_GB@euro. This caused some minor problems with the X-server, which didn't seem to understand what this meant. I changed it to RC_LANG="en_GB" and everything seems to be fine.

Carrying Case

I found a perfect bag for the 240x in Muji, the Japanese homewares store. If you're in London, there is an outlet on Tottenham Court Road near Centre Point.

Links

This is a list of links that I found useful. Thanks to everyone who has put ThinkPad or laptop related suggestions, instructions and encouragement onto the internet. It's all been a big help:

 
 

www.calvino.demon.co.uk Fishcakes... Fishcakes...

We are Alex and Hilde Tingle Liesens.