Installing Debian 3.0 onto an Apple iBook

...without using any physical media!

(fast Internet connection recommended)

(en Français; merci à Jean-Baptiste Fargier)

updated 19 Mar 2003

These instructions should apply to any model of iBook, but they have only been tested by the author on a 2001 iBook Dual USB.

I have a report from a PowerBook G4 (a.k.a. "Titanium PowerBook", a.k.a. "TiBook") owner that these instructions should also work for 550MHz and 667MHz models of that computer.

Update: The new-powermac flavor of the boot-floppies (Debian installer) has been released. This version comes with a 2.4 kernel which should support newer hardware like the iBook Dual USB much better.

Gather information.

Before starting a Debian install, you need to make some decisions and have some information at your disposal.

Prepare the hard drive for Debian under MacOS.

Okay, you're set to begin. How exactly you should handle partitioning depends on how the drive should end up looking; e.g., what operating systems are you going to have installed? A summary of procedures for a number of configurations follows, followed by some more detailed information.

Debian only (congratulations!)

Debian + MacOS 9

Debian + MacOS X

Debian + MacOS 9 + MacOS X

Run the Debian installer.

Now that the four files needed to start the Debian install process are in place, you're ready to proceed.

If you're keeping Mac OS X on the computer, however, you may optionally want to gather one more piece of information; the partition number that will be used by Debian. This will save a little trial and error at the OpenFirmware prompt when you launch the Debian installer. The number used by the partition you have created for Debian will vary depending on how many driver partitions for Mac OS 9 Apple has placed on your hard drive. I know of no way to autodetect the correct number under Mac OS 9, but under Mac OS X, you can simply use the df or mount utilities at the Unix command prompt.

Example of df usage under Mac OS X


In the above example, the two filesystems of interest are the ones that begin with /dev/disk0s. The numbers after the s are slices, which correspond to the partition numbers used in OpenFirmware. Therefore, this user will type boot hd:2,yaboot at the OpenFirmware prompt to launch yaboot on the Debian partition. For my MacOS 9.2-based iBook, bought in 2001, the Debian partition was 9.

Restart the computer and hold down the four keys command + option + O + F. This puts you into OpenFirmware, which is a kind of boot monitor. At the OpenFirmware prompt, type the following:
boot hd:9,yaboot
The digit in this command may differ for your system; see above. If you don't know the number of the partition you have set aside from Debian, try other numbers.

You will next be greeted with the prompt of the yaboot boot loader. Type the following at its prompt:

The Linux kernel will boot and launch you into the Debian installer.

The Debian Installer is extensively documented elsewhere, so I'll just make a few miscellaneous remarks here.

One keyboard type you can select is qwerty/mac-usb-us. Unfortunately, this key mapping has the property of making the Command key the "alt" key, even though the Option key is the one engraved with the word "alt". So keep that in mind; in the Linux console environment, where you see references to the ALT key, use the Comamnd key instead. I have campaigned with the Debian PowerPC porting team to at least take care of the Alt/Command part of this problem, but so far to no success. I'll note cynically that the X server does it right. Alt is Alt. Note: You may be interested in Debian Bug #108433, which has a console keymap attachment which reportedly fixes the switched Alt and Logo keys. (Thanks to Frank Murphy for this pointer.)

Note that you can choose the "regular US layout" in the keyboard type selector, and that will give you Alt on the Alt key (thanks to Michael Shields for this info).

Furthermore -- and this is not Linux's fault -- iBooks require that you hold down the Fn key to get the function keys to scan as function keys. The order in which you press them is important, too! So, to switch consoles, learn this order: Command + Fn + F1 (where F1 might be F2, F3, etc.). When you see <ALT+F4> in the installer, think Command + Fn + F4. Unless, of course, you're using a keymap that doesn't switch the Command and Alt keys, in which case you should think Alt + Fn + F4.

Using mac-fdisk, which is the non-graphical partitioning tool into which the Debian installer throws you on PowerMac-based installs, is a cruel introduction to Debian. Here are a few tips:

Example of mac-fdisk usage

Here's the procedure I went through to partition my iBook's disk in the Debian installer. The dummy MacOS Extended partition I had set aside for Debian appeared as /dev/hda9.

  1. d (delete partition; I am next prompted for the partition number to delete)
  2. 9 (my answer, "partition 9"; this now leaves empty space where I can create the partitions I need)
  3. b (create an Apple_Bootstrap partition; I am next prompted for what "block" at which it should start)
  4. 9p (my answer, "whatever block partition 9 starts at" -- that's the beginning of the space I just freed)
  5. p (take a look and confirm the existence of the new Apple_Bootstrap partition)
  6. c (create partition; I am next prompted for what block the new partition should start at)
  7. 10p (my answer, "whatever block partition 10 starts at" -- unlike MS-DOS partition tables, free space gets numbers you can use for reference, so this is the partition right after the Apple_Bootstrap one I just created; I'm next asked how big it should be)
  8. 1200M (I am creating a 1200 megabyte swap partition -- please don't write in to tell me that's a large swap partition)
  9. swap (I give it the name "swap"; this is important, and I should not call it anything else)
  10. c (create partition; I am next prompted for what block the new partition should start at)
  11. 11p (my answer, "whatever block partition 11 starts at" -- that starts right after the end of the swap partition I just created; I'm next asked how big it should be)
  12. 11p (a size of zero wouldn't make sense, so it knows that this means "wherever this free space partition ends")
  13. root (I give it the name "root"; this is important, and I should not call it anything else)
  14. p (I take another look around)
  15. w (I write the partition table to disk)
  16. q (I quit fdisk)

Run through the rest of the Debian installer, using "http" access methods. You won't need to configure any kernel modules.

Once Debian is installed, you can enable multi-booting with yaboot (if needed), by editing /etc/yaboot.conf and running ybin to commit your changes. For instance, I added the following lines right after the magicboot line in my yaboot config file:

Note that the macosx line points to the MacOS X "Booter" partition, not the UFS filesystem partition. This is important, because OpenFirmware doesn't know how to read UFS partitions.

You can also add
to your /etc/yaboot.conf file to add a CD-ROM boot option to the yaboot menu.

This document will be expanded to address various issues of hardware support on the iBook.

You will need a relatively recent kernel and release of XFree86 to get proper hardware support; this is especially true for Power Macintosh laptops (iBooks and [Titanium] PowerBooks) and even more so for the newer models of these machines released in 2002.

The ATI Rage128 Mobility video chipsets on older iBooks, for instance, are supported by XFree86 4.1, but the ATI Radeon 7500 Mobility on newer iBooks and TiBooks require XFree86 4.2.

Kernel resources:

More info to come; please feel free to email me with updates. My email address is the username associated with this page's URL at Substantial contributions are fine, but thanks to problems in the past, please see the boring legal section below (sorry about that).


To boot from a CD-ROM on a Macintosh: restart the system (by whatever means) and hold down the "C" key when you hear the startup bong. Keep it down until you have visual or aural (i.e., you can hear the CD drive head seeking) confirmation that the system is in fact booting from the CD-ROM.

Yaboot doesn't actually need 800kB; the bootstrap partition is made this large because HFS partitions cannot be made any smaller, and OpenFirmware only knows how to read a few filesystem types.

MacOS 9's Drive Setup program apparently does not know how to create UFS partitions that the MacOS X installer recognizes.

How to translate from Apple's partition type names to the names the rest of the world uses:

MacOS StandardHFS
MacOS ExtendedHFS+
Unix File SystemUFS

Branden Robinson


My sincerest thanks go to the above people for contributing updates.

Valid HTML 4.0! Valid CSS! This site Vim powered. This site managed with Subversion.

Validate this page's HTML.
Validate this page's CSS.

My email address is "branden" (ASCII 64) "debian" (ASCII 46) "org". ASCII 64 is an at sign (@) and ASCII 46 is a period, a.k.a. full stop (.).

$Id: index.html 12 2003-04-18 08:56:33Z branden $