Debian GNU/Linux on an IBM ThinkPad 600E (2645-5AU)

Introduction

Over the few years that I've had this particular laptop for work, I've installed a Linux distribution on it or two. Recently, I've more seriously started running Debian version 3.0, on it. While all distributions in one form or another suck, Debian does provide a fairly useful distribution that is well tested, stable and relatively easy to use for a somewhat more experienced user. I also tend to like how it manages and organizes its packages, both from a systems administration perspective and a licensing perspective. This web page will detail the installation current as of this writing (see the revision history at the end of this page). Note, I did not take extensive notes on all parts of the installation or configuration pieces over the past few months. I'm almost certainly missing some things that may cause you to wonder what you're doing wrong if you are using this as a guide for your own system. If you find any information that may be missing, misleading or incorrect, feel free to contact me and ask for assistance. See my homepage for contact information.

If you are looking for my Mandrake version 7.1 installation notes (my first unix-based install on this hardware), you can find them here: Linux on an IBM ThinkPad 600E (2645-5AU).

Initial Installation

I always recommend installing with CDs whenever possible. CDs are faster and more convenient, especially if you happen to be without network connectivity either intentionally or due to some problems during the installation. I burned the seven CD set of Debian GNU/Linux version 3.0, release 0, code named Woody and dated 20020718.

Debian 3.0 uses a 2.2 Linux kernel by default and that is getting a tad on the old side. If you're paying attention however, you can enable the 2.4 kernel by passing the parameter: bf24 on the command line at the initial installation boot screen. You can view various options and help information from this screen (and I recommend doing so in order to review so you don't miss anything important for your system).

I am not going to detail each install step in detail, since this process will vary based on your own preferences. I'll just highlight a few parameters that others with similar hardware may find useful as a guide or reference.

Sound

The following sound modules were installed with associated parameters (if any):

Mouse
Monitor

The kernel configuration installed by the initial Debian installation was kernel-config-install.txt.

I always customize the installation whenever I have the opportunity and Debian is no exception. Unfortunately, I always get confused somewhere in the process with selecting packages and hit space when I should have hit enter or vice versa. I end up not getting everything I wanted installed on the first try and having to go back and install or remove packages later. I find Debian's overall installation and the dselect tool to be less than satisfying, since it is a pain to work with if you make mistakes in your selections. I would recommend that you get used to using the command line tools such as dpkg and the apt utilities once the system is up and running. With any luck (and lots of help) DesktopLinux.com and the Debian on the Desktop subproject will help make this process easier.

Post Installation Clean-up

A few housekeeping items that help manage the system are listed below. This section may be updated frequently as there always seems to be one more bit of unfinished business.

/etc/apt/sources.list configuration

In Debian, you can choose the types of packages you want to enable for your system (stable, testing, unstable, etc.) by editing the /etc/apt/sources.list file. I tend to favor a very stable setup so my file is simple and it is as follows:

	deb http://http.us.debian.org/debian stable main contrib non-free
	deb http://non-us.debian.org/debian-non-US stable/non-US main contrib non-free
	deb http://security.debian.org stable/updates main contrib non-free
Installed Packages

I generally try to use Debian stable packages whenever possible. It makes troubleshooting a lot easier and potential interaction with other Debian software cleaner in the future. Current package listings as shown by a dpkg -l output is below. In some cases, I have run into a situation, where I have had a package whose status is listed as purge or remove, when in fact I didn't mean to remove it (usually when I discover that some dependency exists). To clear the status back to the install state, simply run something like this: echo package-name install | dpkg --set-selections (substitute package-name for the package whose state you want to reset back to installed. You'll notice that I tend to have packages that are geared towards networking and information security. Much of the software I have installed you may choose to avoid, particularly in those categories.

Account management

I generally avoid logging in as root. Doing so helps prevent serious accidents. However, some common tasks I need require privileges a standard user may not be configured to have by default. If you are in a similar situation, I recommend adding your regular user account(s) to the following groups as necessary (/etc/group):

Rebooting or shutting down by unprivileged users in gnome

An unprivileged user is not able to shutdown or reboot the system from within Gnome. To enable this, I added the gshutdown applet to the panel, but changed the preferences so that it ran a local script that allowed, via sudo, an unprivileged user to shutdown or reboot:

	#!/bin/sh
	#
	# user-shutdown.sh - allow shutdown/reboot from X for unpriv user
	#
	# 2002-12-30,jtk

	echo
	read -p "Do you want to Shutdown or Reboot? [S/R]:" -n 1 -t 360 choice
	echo
	sleep 1

	case $choice in

	s|S)
		echo "Running sudo to verify authorization..."
		if sudo shutdown -h now;
		then
			echo "Shutting down..."
			sleep 1
			exit 0
		else
			echo "sudo failure, aborting..."
			sleep 1
			exit 1
		fi
		;;

	r|R)
		echo "Running sudo to verify authorization..."
		if sudo reboot;
		then
			echo "Rebooting..."
			sleep 1
			exit 0
		else
			echo "sudo failure, aborting..."
			sleep 1
			exit 1
		fi
		;;

	*)
		echo "Invalid entry, aborting..."
		sleep 1
		exit 1
		;;

	esac
	exit 0
Loading Sound Modules

I've found that I've needed to load the ThinkPad sound modules later in the boot process, otherwise sound works poorly (crackles, skipping and generally just wrong :-). Therefore, I've commented out the ad1848, uart401 and cs4232 sound modules from /etc/modules and instead created a start up script to be run later at boot time. You can have these modules load after networking and other essential services that may potentially interfere (I never bothered to figure out exactly what the problem is) by naming it something like S79sound in your /etc/rc<2-5>.d directories (linking to ../init.d/sound preferably):

	#!/bin/sh
	#
	# sound - start sound subsystem modules
	#
	# 2002-12-30,jtk

	case $1 in

	start)
		echo "Starting sound subsystem..."
		insmod isa-pnp
		insmod ad1848
		insmod uart401
		insmod cs4232 io=0x530 irq=5 dma=1 dma2=0
		;;

	stop)
                echo "Stopping sound subsystem..."
		rmmod cs4232
		rmmod uart401
		rmmod ad1848
		rmmod isa-pnp
		;;
	*)
		echo "Usage: $0 {start|stop}"
	        exit 1
	;;

	esac
	exit 0
Enabling the playback of DVDs

I installed the ogle-mmx package and associated libraries. In order to play encrypted DVDs, I theoretically could have also installed the libdvdcss package as specified in the configuration screen for Ogle. I'm uncertain of the legal status for libdvdcss, so I'll leave it at that. Ogle by default looks for /dev/dvd so from the /dev directory I ran: ln -s hdc dvd (Assuming your CD-ROM/DVD drive is /dev/hdc, adjust as appropriate). Also, for unprivileged users, read-write access to the DVD drive may be required for use. To enable this, run: chmod 666 /dev/hdc (verify your CD-ROM/DVD drive is actually /dev/hdc first!). Finally, DMA transfer mode for /dev/hdc was disabled by default. In order to get decent playback performance out of the DVD drive, I ran: hdparm -d 1 /dev/hdc and also put this in a startup script:

	#!/bin/sh
	#
	# dmadvd - enable dma transfer on cd/dvd
	#
	# 2002-12-30,jtk

	case $1 in

	start)
		echo "Enabling DMA on CD/DVD drive..."
		hdparm -d 1 /dev/hdc
		;;

	stop)
		echo "Disabling DMA on CD/DVD drive..."
		hdparm -d 0 /dev/hdc
		;;

	*)
		echo "Usage: $0 {start|stop}"
		exit 1
		;;

	esac
	exit 0

In order to have a CD or DVD be automatically available upon boot-up, I adjusted the /etc/fstab file line as follows:

	/dev/cdrom	/cdrom		auto	ro,user,auto		0	0
Disabling BEEPs

Controlling the annoying BEEPs your system makes is probably desirable. Obviously you can set the system volume with the Fn-PgUp/Fn-PgDn keys. The software volume mixer can then be used to set application volumes. On the Linux ThinkPad mailing list, the following other options have been suggested:

Enabling Mozilla ALT-arrow page forward/backward key sequences

I am using Mozilla under Sawfish/Gnome primarily. I often use key sequences rather than the mouse. In Netscape/Mozilla I've gotten used to the ALT-arrow key sequences to move forwards and back in browsing pages. Sawfish by default maps those key sequences to movement between different workspaces. I changed those key sequences to use the Ctrl key instead of the Alt key in the Shortcuts section of the Sawfish window manager control center.

Replacing Lilo with Grub

Debian 3.0 still uses Lilo as its default boot loader. While Lilo is fine, Grub is the becoming the more common boot loader for modern distributions since it has some enhancements and advantages over Lilo. Grub is relatively easy to install. Once you've grabbed the package, simply run: grub-install /dev/hda (be sure /dev/hda is your boot device and you want it installed on your MBR!). Then edit the grub/menu.lst file to suit your preferences. I recommend enabling the password --md5 option to protect the system from unauthorized physical level security kernel access in the boot sequence. You use the grub-md5-crypt command to get the md5 hash for a password of your choosing. Once you've made all the necessary changes to the Grub menu, run: update-grub. You can later remove Lilo from the system.

XF86Config-4 changes

The version of XFree86 that came with the initial Debian installation and its associated configuration via debconf worked well enough. However, I disabled the management of it later by running: dpkg-reconfigure xserver-xfree86 and saying no to letting Debconf manage the server's configuration. I only needed to make a couple of minor adjustments. In particular, I enabled the capability to use both the external and internal display.

Custom kernel

In order to enable various features, drivers and protocols for my system, I built a custom kernel the Debian way. This involves building a custom Debian package and using make-kpkg and dkpg to build and install it respectively. The following packages were minimally required to build a customer kernel:

Updated kernel-pkg.conf with my name and email address. At first I grabbed the alsa and pcmcia packages, but after some experimentation, I realized I didn't really need them and in the end ended up not using them. From /usr/src I unpacked the kernel source, then ran: make xconfig as a normal user in the /usr/src/linux directory. The configuration is as follows:

To install the new kernel, the following was done:

Kernel notes

I needed to enable CONFIG_FILTER in the kernel in order to use ISC's dhclient (it requires it).

No longer seem to need isapnp module for sound.

I needed to enable CONFIG_RTC, otherwise I had a message about not being able to load char-major-10-135, which is used by /dev/rtc.

I did not need pcmcia-cs, I use the native support support built into the kernel since I only have a need for 32-bit cards at the moment.

You'll note that I enable lots of things you may not want. This includes things like IPv6 and security services. Overall however, this provides a fairly robust kernel at almost half the original size that was part of the original install.

There are a few other things that aren't quite perfect yet, mostly involving kernel modules that I need to get have load optimally or fix dependency issues. They will documented here as I get to them.

### TODO - custom networking

Bugs

The current setup is not perfect and will probably never be. This is especially true as I tend to prefer to run stable packages as opposed to newer software that may often fix some of the issues I run into. There is a trade-off of course. This section documents some of the problems I've run into and any details I have about resolving the issue in the future. I will try to avoid putting anything here that is not a bug (e.g. I've exhausted all my ability to verify I am not doing anything wrong), but it is possible I am missing something. If so, please let me know.

Gabber artifacts

On occasion I've noticed that Gabber sometimes leaves artifacts on the screen. This seems to happen whenever I've started the application, but failed the initial server login. This may happen if a previous session was saved while logged into a Jabber server with Gabber. The symptoms include the Add Contact icon persisting on all workspaces. Clicking on it will work as if the application is there.

Copy and paste fails from Gnome terminal to other Gnome apps

I am unable to copy and paste text from a Gnome terminal console to other windows except to another Gnome terminal. The reverse is not true, I can copy text from other Gnome apps and paste into the Gnome terminal just fine. This appears to be a known bug, but does appear to be applied to the stable Gnome package in Debian as of yet.

ThinkPad sound modules must be loaded at a certain boot time

I have had to load the isa-pnp, ad1848, uart410 and cs4232 modules near the end of my system's boot process in startup files to avoid problems with the sound system. I stopped testing at some point, but I had to assume that the sound modules conflict with some other service(s) that load before it so the order in which they load is important. Since I'm using the older OSS modules now, I'm not going to worry about this much as I do plan on moving to the ALSA sound system at some point in the future.

AbiWord crashes on opening Microsoft Word documents

AbiWord tends to have problems with complex Microsoft Word documents. In fact, AbiWord seems to behave badly when it encounters a file it can't import, usually resulting in a crash. KWord tends to generally handle Microsoft documents better, but even then, the formatting is usually lacking. I've found OpenOffice to work well on other systems, but I'm going to see if I can wait for an official Debian stable package of it, before installing it on this system. I've submitted a Debian bug for this problem, though it doesn't appear the maintainer is actively managing AbiWord bugs. I don't want Microsoft formatted documents anyway, so I'm not too worried about it. Debian Bug #176299.

References

Revision History