Last Updated: 9/31/2006
I just got a new IBM T60p for work, and as I went through the process of installing and configuring Linux, I kept thinking to myself, "I wish I had written all this down when I installed my other laptop ... it would be so much easier this time." (duh!) I'm sure that I thought the same thing when I installed my previous machine, and the one before that, and the one before that, etc. This time, I'm actually going to do it, though. Hopefully, someone else can get some benefit out of these notes, too.
I make no guarantee about the suitability of these instructions for use on your machine. Use them at your own risk. If your computer breaks, I'm sorry, but it's not my fault.
Here's a list of the important stuff in the T60p:
If it's not listed here, then it wasn't important to me, and I didn't try to make it work. If it's listed here but there are no specific notes about it below, then it just works. If there's something you want to figure out that I don't discuss here, you should check Linux On Laptops and/or the ThinkWiki T60p page.
0000:00:00.0 Host bridge: Intel Corporation Mobile Memory Controller Hub (rev 03) 0000:00:01.0 PCI bridge: Intel Corporation Mobile PCI Express Graphics Port (rev 03) 0000:00:1b.0 0403: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 02) 0000:00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 02) 0000:00:1c.1 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 2 (rev 02) 0000:00:1c.2 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 3 (rev 02) 0000:00:1c.3 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 4 (rev 02) 0000:00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #1 (rev 02) 0000:00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #2 (rev 02) 0000:00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #3 (rev 02) 0000:00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #4 (rev 02) 0000:00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 02) 0000:00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2) 0000:00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 02) 0000:00:1f.1 IDE interface: Intel Corporation 82801G (ICH7 Family) IDE Controller (rev 02) 0000:00:1f.2 0106: Intel Corporation 82801GBM/GHM (ICH7 Family) Serial ATA Storage Controllers cc=AHCI (rev 02) 0000:00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 02) 0000:01:00.0 VGA compatible controller: ATI Technologies Inc: Unknown device 71c4 0000:02:00.0 Ethernet controller: Intel Corporation 82573L Gigabit Ethernet Controller 0000:03:00.0 Network controller: Intel Corporation: Unknown device 4227 (rev 02) 0000:15:00.0 CardBus bridge: Texas Instruments PCI1510 PC card Cardbus Controller
Pop in the Ubuntu Live CD and click the "Install" icon from the desktop when it finishes booting. The new installer is really easy to use if you're looking for a plain vanilla install. The only non-standard thing I did was setting up my partitions.
There is a small partition at the end of the disk that's used for recovery. In the standard configuration, it comes up when you press the ThinkVantage button. Grub will recognize it as a Windows partition and put it in the grub menu. If you every want to access the recovery tools after install, simply boot this partition from the grub menu, since the ThinkVantage button won't work any more after you install grub to the MBR. Most of the tools won't work for me, since I don't have a Windows system on the machine. However, someone with a dual boot configuration will probably be happy to have left that partition alone.
I used custom partitioning, and blew away all but the last partition, and then created one big extended partition from all the available space. I made three logical partitions for /, /home, and /usr/local, and then moved on to the next screen without adding a swap partition. I then went back to the partitioning screen and found that there was around 6GB of space that wasn't in a partition (even though I had specified that my extended partition would take all available space). I turn the 6GB partition into my swap partition. If I remember correctly, I may have had to exit the installer and restart after partioning so that the later screens (after the partitioning screen) would recognize the new swap partition.
After the base install was complete and the machine had rebooted, I
installed a bunch of other stuff that I need. The one thing that
everyone should do is: sudo apt-get install
linux-686-smp. I also recommend setting a root passwd
(sudo passwd root) so that you can boot into recover mode
if something goes wrong in the future. And finally, I changed this
line in /boot/grub/menu.lst:
# defoptions=quiet splash
# defoptions=nosplash
Both network cards works just fine. I didn't have to do anything special to get them to work. The one unusual thing that I do is to setup /etc/network/interfaces to automatically determine whether I'm at home or at the office (or somewhere else), and configure the network accordingly. Also, I generally only want to use one of the network devices at a time (either wired or wireless), so I set things up to ensure that the wireless card only activates if there is no cable plugged in to the wired card. Some folks tell me I should just use the laptop-net package, but I know how to do it my way, and so I don't see any reason to learn the other way (unless I'm really bored at some point in the future).
auto lo iface lo inet loopback auto eth0 mapping eth0 script /usr/local/bin/wireless-scheme map my-wireless-essid 00:00:DE:AD:BE:EF wireless-home map wireless-external ANY wireless-office map ANY ANY wireless-othernet iface wireless-home inet static address 192.168.1.3 netmask 255.255.255.0 gateway 192.168.1.1 dns-nameservers 192.168.1.1 wireless-essid my-wireless-essid iface wireless-office inet dhcp wireless-essid wireless-external iface wireless-othernet inet dhcp wireless_essid any mapping eth1 script /usr/local/bin/wired-scheme map 192.168.1.4 255.255.255.0 192.168.1.1 wired-home map IGNORE IGNORE IGNORE wired-othernet iface wired-home inet static address 192.168.1.4 netmask 255.255.255.0 gateway 192.168.1.1 dns-nameservers 192.168.1.1 iface wired-othernet inet dhcp
#!/bin/bash if [ `id -u` -ne 0 ] || [ "$1" = "" ]; then exit 1; fi IFACE=$1 WHICH="" if [[ -z "$IFACE" ]]; then exit 1; fi if ! ifconfig "$IFACE" up 2> /dev/null; then exit 1; fi if ! ifconfig "$IFACE" 2> /dev/null | grep -q 'RUNNING'; then echo "Ignoring Wired Connection: $IFACE not connected" >&2 ifconfig "$IFACE" down 2> /dev/null exit 1; fi while read ADDR NETMASK PINGPOINT SCHEME; do if [[ -n "$WHICH" ]]; then continue; fi if [[ "$ADDR" == "IGNORE" && "$NETMASK" == "IGNORE" && "$PINGPOINT" == "IGNORE" ]]; then WHICH="$SCHEME" continue fi if ! ifconfig "$IFACE" "$ADDR" netmask "$NETMASK" up; then continue; fi if ! ping -c 1 "$PINGPOINT" >& /dev/null 2>&1; then continue; fi WHICH="$SCHEME" continue done ifconfig "$IFACE" down 2> /dev/null if [[ -n "$WHICH" ]]; then echo "$WHICH"; exit 0; fi exit 1
#!/bin/bash if [ `id -u` -ne 0 ] || [ "$1" = "" ]; then exit 1; fi IFACE="$1" WHICH="" # do nothing if eth1 is already running if ifconfig eth1 2> /dev/null | grep -q 'UP'; then echo "Ignore Wireless Connection: eth1 is active" >&2 exit 1 fi # do nothing if eth1 is plugged in if ifconfig eth1 up 2> /dev/null; then if ifconfig eth1 2> /dev/null | grep -q 'RUNNING'; then echo "Ignore Wireless Connection: eth1 is connected" >&2 ifconfig eth1 down 2> /dev/null exit 1 fi ifconfig eth1 down 2> /dev/null fi # now try to determine the wireless scheme while read ESSID MAC SCHEME; do if [ -n "$WHICH" ]; then continue; fi if ! ifconfig "$IFACE" up; then exit 1; fi if ! iwconfig "$IFACE" essid "$ESSID"; then continue; fi if [[ "$ESSID" == "ANY" ]]; then ESSID=".*"; fi for (( i=0; i<10; i++ )); do sleep 1 if [[ "$MAC" != "ANY" ]] then if iwlist "$IFACE" scan | egrep -q "Address: $MAC" then WHICH="$SCHEME" fi else if iwlist "$IFACE" scan | egrep -q "ESSID:\"$ESSID\"" then WHICH="$SCHEME" fi fi if [[ -n "$WHICH" ]] then echo "Configuring $IFACE using scheme $WHICH ..." >&2 echo $WHICH exit 0 fi done ifconfig "$IFACE" down 2> /dev/null done exit 1
The ATI card in this machine isn't supported by the open-source radeon driver in Ubuntu Dapper. If you don't want to use the proprietary driver, then you'll have to use vesa, and settle for no external monitor. Since I use a dual head setup at work, I have to use the fglrx driver. Of course, that also means that I get 3D support too, which is also a good thing.
The monitor I plug in at work is a Dell 24-inch widescreen. The laptop screen at 1400x1050 has 126 DPI, and the widescreen has 96 DPI, so I don't use Xinerama, since it can't handle multiple resolutions. The fglrx driver doesn't provide very good pseudo-Xinerama support (they call it big desktop mode). It does't different DPIs or different screen sizes very well. The open-source radeon driver does a great job with this, so I wish I could us it instead. I just have to settle for not being able to drag windows from one screen to the other and not having unified window/task lists in XFCE.
For some reason, X was using the wrong resolution for the widescreen (72x72), so I explicitly set the DisplaySize values for both screens in my configuration (see below). This solved the problem.
Here are the parts of my xorg.conf that I had to tweak.
Section "ServerLayout" Identifier "Default Layout" Screen 0 "laptop screen" 0 0 Screen "wide screen" Above "laptop screen" InputDevice "Generic Keyboard" InputDevice "Configured Mouse" InputDevice "Synaptics Touchpad" #Option "Xinerama" "true" EndSection Section "Monitor" Identifier "laptop monitor" DisplaySize 282 212 Option "DPMS" "true" EndSection Section "Monitor" Identifier "widescreen monitor" HorizSync 30-81 VertRefresh 56-76 DisplaySize 513 324 Option "DPMS" "true" EndSection Section "Device" Identifier "laptop device" Driver "fglrx" BusID "PCI:1:0:0" EndSection Section "Device" Identifier "widescreen device" Driver "fglrx" BusID "PCI:1:0:0" Screen 1 EndSection Section "Screen" Identifier "laptop screen" Device "laptop device" Monitor "laptop monitor" DefaultDepth 24 SubSection "Display" Viewport 0 0 Depth 24 Modes "1400x1050" EndSubSection EndSection Section "Screen" Identifier "wide screen" Device "widescreen device" Monitor "widescreen monitor" DefaultDepth 24 SubSection "Display" Viewport 0 0 Depth 24 Modes "1920x1200" EndSubSection EndSection
My desktop environment of choice is XFCE. Most of it's underlying utilities work well with the switch between dual monitor mode and single monitor mode. The only exception to this is the panel. In dual monitor mode, I need to configure two panels, one for each screen, since the panel applications (pager, tasklist, etc.) are screen specific. However, after that, if I start XFCE in single monitor mode, it complains about the panel configuration, since it doesn't know where to put the second panel. To work around this, I added my own ~/.config/xfce4/xinitrc script that figures out how many screens I have, and sets up a symlink to the correct, pre-configured panel configuration file for the number of screens.
#!/bin/bash SCREENS="$(xdpyinfo | awk -F: '$1 == "number of screens" { print $2; }')" rm -f $HOME/.config/xfce4/panel/panels.xml if (( SCREENS == 2 )); then ln -s panels-dual.xml $HOME/.config/xfce4/panel/panels.xml else ln -s panels-single.xml $HOME/.config/xfce4/panel/panels.xml fi # now run the standard system xinitrc to do the real start exec /bin/bash /etc/xdg/xfce4/xinitrc
I had to get my panel configuration just right first, because XFCE will overwrite my symlink with the new panel config on change, rather than the file that is linked to, and my panel config changes will be lost when I next log in. That's OK for me, because I know exactly how I want the panels.
Use the above instructions at your own risk. If something breaks, don't blame me ... it all worked on my computer. With that said, if something doesn't work and you figure out a different/better way, please consider posting your own T60p instructions at Linux on Laptops and/or contributing to