Hands on: A close-up look at Mac OS X's NetBoot

One of the most interesting technologies in Mac OS X Server is NetBoot and its close cousin, NetInstall. NetBoot allows you to start up a Macintosh computer from a network disk image rather than using a local disk (hard drive, CD, etc.). NetBoot offers some distinct advantages for administrators: It allows a consistent user environment that can't be modified, it makes rolling out new software or configuration changes easy, it can allow a user access to a computer when the hard drive is corrupted or damaged, and it can be used as a method for deploying a disk image onto new workstations.

Here's a look at NetBoot, how it works and how it can make your life as a Macintosh systems administrator easier. First, remember that NetBoot and NetInstall are two different things. NetBoot is designed for a Macintosh to boot using the disk image on a server instead of on the local hard drive, although the local hard drive may still be accessible to users. Typically used in academic or public lab settings, NetBoot allows users access to the computer but doesn't let them store any files or settings. It allows the operating system and applications to be loaded from the server. NetInstall, on the other hand, only allows access to the Mac OS X Installer files, so it's usable only for performing new OS X installations without the installer CDs. Although Apple Computer Inc. provides tools for modifying the default NetInstall settings to include software update packages and third-party applications, I have found this functionality difficult and time-consuming to use -- at best -- and completely nonfunctional most of the time.

Ryan Faas

Creating a NetBoot Image is fairly straightforward. Mac OS X Server comes with the Network Image Utility, which can easily build a NetBoot image of a generic Mac OS X installation. This utility also creates all of the needed support files in the appropriate locations. However, I know of no administrator who has a use for a completely generic installation with no additional applications or other modifications. That's where something such as Mike Bombich's freeware Carbon Copy Cloner comes in handy: It allows you to create a disk image from any hard drive (much like Apple's Disk Copy) and includes an option for making that image into a NetBoot Set. Doing so creates not only the image, but all of the additional support files that will be needed.

One of the big concerns most people have is that using NetBoot will take up a large amount of bandwidth. This is a definite concern, and no one should attempt using NetBoot without having 100Base-T or faster connections to the workstations that will be booted from a server. That said, NetBoot isn't as bandwidth-intensive as you might think. The only time NetBoot will create bandwidth problems is if multiple computers are booting from the server simultaneously.

In my experience, booting more than five computers at a time on a single 100Base-T subnet takes a toll on bandwidth.

One solution to this problem is to create separate subnets for NetBoot computers. In most switched environments, this can be done with relative ease. Unfortunately, there is a downside. In order for NetBoot to function effectively, workstations need to be on the same subnet as the server. Although Apple does suggest that with appropriate packet-forwarding enabled in a routed environment, NetBoot should work across subnets, I know of no one who has managed to do this with any real degree of success. A better solution is to stagger the booting of multiple computers. Once a computer has completed its boot sequence, it requires very little bandwidth. Therefore, I've found that booting computers in blocks of one to four workstations works best. When the first block is finished booting, power up the second block. When it's done, move on to the next.

Under the hood with NetBoot

Although Apple's documentation includes information about how to configure NetBoot properly, it doesn't include a concise explanation of the process that occurs. Here, for the sake of reference, is a brief synopsis of the process:

The NetBoot client broadcasts a request for a Dynamic Host Configuration Protocol (DHCP) server. The DHCP server -- whether a Mac OS X server or another computer -- responds and the client and server establish the client's IP address. The client then broadcasts a request for a Bootstrap Service Discovery Protocol (BSDP -- a.k.a. NetBoot) server. The server responds with an acknowledgement packet. The client responds to the acknowledgement with options, such as which operating system or disk image set it wishes to use for boot.

At this point, the server responds with a packet containing the path for the basic files needed by the client to begin its start-up process, such as the Mac OS read-only memory file in Mac OS 9 or the boot files for Mac OS X. The client then issues Trivial File Transfer Protocol requests for those files and downloads them. This is the point at which the Apple logo and spinning globe appear on the client's screen. Once these files have loaded, the client machine begins loading the actual disk image and then begins the Mac OS start-up sequence as though the files were residing on a local hard drive.

If the image is a Mac OS X installation, the client creates a copy of the disk image (called a shadow file) on the local hard drive, if a functional hard drive is present. Any access to the image actually hits the local hard drive rather than the server, which results in better response times and negligible bandwidth usage. If the disk image is a Mac OS 9 installation, a shadow file is also created, but it exists on the server, which requires more bandwidth as files on the image are accessed and decreases performance. Looking for more Macintosh news? Be sure to sign up for Computerworld's biweekly Macintosh newsletter.

Copyright © 2003 IDG Communications, Inc.

7 inconvenient truths about the hybrid work trend
Shop Tech Products at Amazon