LJ Archive

LinuxPPC 1999

Stephane Morvan

Issue #70, February 2000

How to install Linux on your Power Macintosh to gain a robust alternative to the MacOS.

There are some very significant things about LinuxPPC and the Macintosh that make installing LinuxPPC a challenge for Mac users. For one, no matter how hard you look, MacOS (the Macintosh Operating System) does not feature a command line or anything remotely resembling one. Fortunately enough, with this release of LinuxPPC 5.1, LinuxPPC, Inc. has done a great job of making the intrinsically complicated installation process easy with their X-based installer. Although the process is not perfect or free from any defects, it does a good job of bridging the gap between a 100% graphical OS and a 100% fundamentally command-line OS.

About LinuxPPC

LinuxPPC, along with MkLinux and NetBSD, are the three flavors of Linux that can be found for Macintosh computers. LinuxPPC supports some very exotic hardware, with various degrees of functionality: BeBoxes, Motorola Powerstacks (a PowerPC-based machine capable of running a defunct WindowsNT), IBM AIX machines (PowerPC-based, such as the Thinkpad 8x0 series) and Apple's discontinued Network Servers (which ran only AIX). Most users run LinuxPPC on Macintosh hardware, whether from Apple or from the late clonemakers (Umax and PowerComputing). A wide array of platforms are supported from old Performas (6360, 6400 series) to the latest B&W G3, Powerbooks G3 and all iMac flavors.

The name LinuxPPC 1999 refers to the most recent version of LinuxPPC, in this case version 5.1, which is a minor update to v5.0. Thus, the name LinuxPPC 1999 and LinuxPPC R5.1 may be used interchangeably.

Essentially, LinuxPPC R5.1 is based on Red Hat 6. This may sound like old news for x86 users, but LinuxPPC was almost an entire year in gestation. On June 10, 1999, the CDs shipped out to patient users. LinuxPPC 1999 follows from LinuxPPC 1998, another Red Hat-based distribution (Red Hat 5). This last release brings some very significant improvements over the previous version, including XFree86, glibc 2.1-based, USB support with 2.2 kernels, a wider array of window managers (WindowMaker, Enlightenment), linuxconf support and Netscape Communicator 4.6 to name a few. Furthermore, switching from the MacOS to LinuxPPC has never been easier, due to the introduction of Benjamin Herrenschmidt's BootX 1.1, a utility that makes flirting with the buggy OpenFirmware settings a thing of the past.

I have successfully installed LinuxPPC on a variety of platforms I have owned over the past years: a Performa 6360 (PPC 603ev, 160 MHz), a PowerMacintosh 6500/275 (PPC 603ev 275 MHz, ATI RageII), a Powerbook G3/3500 (PPC 750 250 MHz, Chips and Technologies 65554) and on my latest acquisition, a Powerbook G3/266 (PPC 750 266 MHz, ATI Rage Pro LT).

Installing LinuxPPC 1999

Installation has never been so straightforward: there's the choice of an X-based installer, running on a minimum live file system (with shells and WindowMaker), and for more confident users, the Red Hat installer.

The most difficult step to be carried out during the installation process is partitioning the hard drive. Although this is by no means a complicated operation, it has to be carried out cautiously to prevent any loss of data on MacOS partitions. It should be noted that, although LinuxPPC is becoming a mature distribution, users are expected (read required) to polish the edges by manually tuning their installation and resolving some minor problems. First-time users are often frustrated at this point: between the use of vi and the large number of configuration files to be edited, their MacOS experience falls short of helping them conquer the final hurdles.

LinuxPPC, however, and for that matter most Linux distributions, are built on the premise of experience capitalization: from the resolution of a problem, so much is learned of the system itself that the next problem is tackled efficiently.

Installing with the X-based Installer

The installation process starts by launching the LinuxPPC 1999 Installer, having the live file system on a local volume and rebooting the machine into LinuxPPC (using BootX). The installation can access the distribution whether it is located on a CD-ROM, HTTP, FTP or NFS. An excellent 68-page installation guide is provided to cover the common pitfalls, and prospective users should consider reading it several times before attempting the installation.

By far, the simplest and safest installation process is with the $40 CD-ROM sold by LinuxPPC (or any custom-made CD-ROM with long file name support). Although the FTP installation is equally easy, it requires a relatively fast and reliable Internet connection and support present in the kernel for the Ethernet hardware. The local installation, which involves downloading the RPM files from one of the FTP sites to a MacOS volume, can be equally challenging: MacOS does not support long file names (in excess of 32 characters) and the name truncation is often FTP client-dependent. Furthermore, HFS+, the updated version of the MacOS file system HFS, is not supported in LinuxPPC. Hence, a local distribution should be on an HFS volume only. A custom CD-ROM can be recorded on any PC in the ISO9660/HFS Format with Rock Ridge Extensions (with long file name support). The DOS version of mkhybrid can be used to generate the ISO image file supported by most CD mastering software.

Nevertheless, once the source installation issue is addressed, the installation process involves six steps:

  1. Partition the hard drive (1GB as root and 200MB as swap are recommended).

  2. Choose and configure the installation method.

  3. Choose the packages to be installed (minimum installation is 400MB).

  4. Enter the root password.

  5. Configure the network.

  6. Reboot the machine.

Although there aren't any major issues to be resolved during the installation, I noticed the output shell is overly verbose. It reports errors which appear to be are serious, but which do not prevent the installation process from concluding successfully.

Once the machine is restarted, the user may be faced with the first problem as the screen cycles a number of times displaying a hieroglyphic message stating that a process is respawning too fast, and as a result, another process was murdered mysteriously. Fortunately, the cycling pauses for five minutes after a number of attempts, which is enough time to log in as root and solve the problem. The resolution is described at the LinuxPPC web site, under the updates section. Once this problem is resolved, the system boots in runlevel 5, and it presents us with GNOME and Enlightenment and an Xlogin screen. From there, customization of the environment and installation of new packages are simple matters common to most other Linux systems.

Installing with the Red Hat Installer

The Red Hat-based installer is geared somewhat more toward the command-line user, though other users should not anticipate any difficulties with it. Perhaps the most stringent problem arising with this installer is the difficulty of going back and making changes to adjust for a problem encountered during the installation.

Nevertheless, booting in the Red Hat installer is very simple. Either add an option to the kernel arguments in BootX (; redhat) or remove the live file system from the MacOS (renaming it is sufficient). The installation process then prompts for various configuration information: keyboard type, type of installation (upgrade or new install), source installation (FTP, NFS, local or CD-ROM), and the partitioning step. Rebooting the computer after the partitioning step is required rather than suggested as per pdisk instruction, otherwise the file system may be corrupted. Then the file system is configured, the mount points are set, and the package selection is proposed. Once installation of all packages is finished, the installer will try to configure the X Server (e.g., by editing /etc/X11/XF86Config). Unfortunately, this operation will likely fail in a frustrating manner; the workaround to this problem is proposed later.

Then, the root password is set and the system is rebooted. Since the X Server configuration failed, the system will boot in runlevel 4 until the X Server is properly configured.

About the X Server: XF68_FBdev

The current implementation of XFree86 is somewhat peculiar to LinuxPPC: the incantation of the X Server is XF68_FBdev, written by Geert Uytterhoeven. This X Server uses a hardware abstraction for the frame buffer by creating a special device file in /dev/ (usually /dev/fb0) and using it to drive the graphics. As with any devices/special files, kernel support is required. The default driver for the frame buffer device is called the open firmware frame buffer (offb). This driver is common to all Macintosh computers, which makes it inherently slow, hence the poor graphics performance of a basic installation (or the total failure thereof).

Fortunately, patches are available to build a kernel to support a particular frame buffer. Such is the case for Apple Powerbooks (1998: G3/233, G3/250, G3/266, G3/292 and G3/300) sporting an ATI Rage controller (either RageII LT or RagePro LT) with 4MB SGRAM. Booting with such a patched kernel will provide users with accelerated 2-D graphics, and an overall improved experience with the X Server (often mistakenly associated with the overall system speed, by first-time users).

To configure the graphics for such a kernel, do the following:

  • Pass the correct kernel arguments in BootX to indicate the use of another frame-buffer device, screen size, screen depth and refresh rate. For instance, to boot in 1024x768x32@60Hz on a Powerbook G3/266, use the following:

        video=atyfb:vmode:14,cmode:32,pll:135,mclk:60
  • Once the booting process is finished, run Xconfigurator. Note that the correct amount of VRam is now detected. Select a monitor which suits your needs and the resolutions to be used.

  • Let Xconfigurator try to start the X Server; in the event it fails, be sure to select at least one configuration at 8bpp. In the event it keeps failing to start the X Server, select another monitor.

  • Start the X Server using startx.

Xconfigurator edits the /etc/X11/XF86Config file for specific hardware. Admittedly, this is more work than most users are willing to do, and there is no guarantee that the list of monitors provided will match a particular monitor. Fortunately, some alternate X Servers are available. Such X Servers are Xpmac and Xpmac_mga (accelerated), which are essentially software-only X Servers (although Xpmac_mga offers a degree of acceleration on some hardware). Installing them requires simply copying them to /usr/X11R6/bin in an existing XFree86 installation and linking X to either Xpmac or Xpmac_mga.

Conclusion

All in all, while this version of LinuxPPC certainly has its flaws, once the problems are resolved, the system is rock-solid and very responsive. Furthermore, the LinuxPPC community is fairly responsive. The support newsgroup is a great source for help on most common problems, as are the mailing lists. Hardware support is currently at its best, as most devices do function properly (even PPP works). For Mac users on the search for a robust alternative to the MacOS, whether for development or server applications, LinuxPPC certainly delivers the goods.

Resources

Stephane Morvan can be reached via e-mail at smorvan@ces.clemson.edu.

LJ Archive