Mac Web Servers: February 18, 2002

Mac OS X Web Servers

by David L. Hart
An Excerpt from the Mac OS X Web Server Handbook
See the Chapter 7 page for the links referred to in this excerpt.

Now we've come to the chapter you've been waiting for, or perhaps been skipping ahead to -- installing a Web server on your Macintosh. And in this chapter, we'll discuss not one, but three Web servers. Apache, the most popular Web server software on the Internet, and freeware that's bundled with Mac OS X. The Apache section will also discuss iTools from Tenon Intersystems for configuring and administering an Apache server. WebSTAR is the leading Web server for the Mac OS and will soon be available as a native Mac OS X application. Finally, we'll mention Web Server 4D, the third major Mac OS Web server with a number of interesting features.

In addition, other shareware or freeware Mac OS Web servers have various capabilities and levels of current support. It's not clear how many programs will be revised as native Mac OS X applications that can take advantage of Mac OS X high-end features. You may have to run them as Classic Mac OS applications that will not benefit from the memory protection and preemptive multitasking of Mac OS X.

CHOOSING A WEB SERVER

Rather than recommending a particular Web server, the goal of this chapter is to help you evaluate which software is right for you. You should keep the following features in mind as you test the Web servers described or mentioned in this chapter.

Cost. Not all servers are free. Whether you buy a server should depend on the support services you need and not necessarily on software quality. Free Web servers, such as Apache, are generally of high quality. Also remember that "cost" does not always equal the price you pay for the Web server. You should also consider the cost of installing and managing the server, the cost of software needed to support services not included in the server software, and other factors.

Performance. You probably want the Web server that delivers the best performance for the money. But you can define performance however you like. For some Web sites, hits per second is the most valid measure. For others, it might be the amount of data that can be moved or the average time between crashes. For e-commerce sites, it might be secure transactions per second.

Administration. For some webmasters, such as those running servers housed at a Web hosting company's facility, it might be vital that a Web server permit Web-based administration. For part-time webmasters at small companies, administrative ease of use might be most attractive. Most servers can be configured to take particular actions based on file type, and if you will be serving up many different types of files, you might consider the server's support for many MIME types, and extensibility to support for new MIME types.

Security Features. This topic is important enough to merit its own section in this chapter. For now, suffice it to say that security can mean both controlling access to all or portions of the data served at your site and protecting private information being exchanged between your customers and your server.

IP Multihoming or Virtual Hosting. In many instances, you may need your Web server software to handle requests for several different Web hosts on the same machine -- perhaps a public Web site, a private intranet site, and some project hosts. You may then want your server software to support IP multihoming or virtual hosting. This feature is generally more common in commercial software and may make administration a bit more complex.

Extensibility. You won't want to update your Web server software each time a new Web technology is developed. WebSTAR and compatible servers allow you to add plug-ins -- similar to Web browser plug-ins -- with new processing capabilities to your server. Apache has modules that perform the same role. Other servers provide other means of extending the basic server functionality.

Additional Services. Some commercial packages, such as WebSTAR and iTools, provide more Internet services besides a basic HTTP server. A search engine, an FTP server, an e-mail server, database publishing, or e-commerce features are some of the extra services that might factor into your decision. Having all these features built into one piece of software from one company may be important from a technical support standpoint if you are a part-time webmaster, for example.

Log Formats. Every event performed by the server is logged to a file. In general, you should look for logging that supports the CERN/NCSA common log format. If the server software supports the common log format for its log files, you can be fairly certain that standard log analysis tools will be able to read and analyze the log files.

Server-Side Includes (SSIs). An SSI is similar to an Include statement in a number of programming languages. For example, rather than manually inserting the date the Web page was last modified into the HTML each time you modify the file, you can simply include a function that returns the modification date based on the file modification date retained by the Mac OS. In any but the most secure environments, SSIs or similar server-interpreted functions help webmasters create easily managed Web sites. You may want to examine the range of functions provided by the server.

If you think this is a large number of considerations, note that it is only a partial list. Table 7-1 provides some links to more information on Web servers, features, and comparisons. Table 7-2 lists some of the available Web servers for Mac OS X and includes those servers that run as native Mac OS X applications. Table 7-3 lists Web server applications that, at the time of writing, either are no longer being developed or supported, or will only run in the Classic environment without the benefit of advanced Mac OS X features.

I should also mention what Tables 7-2 and 7-3 do not list, and that is applications that include a Web server, but for which the main function is not Web serving. For example, they do not include database, application, or targeted e-commerce servers that also have built-in Web server capabilities. These programs will be discussed in subsequent chapters. Of course, no matter what dividing line is used, some applications will straddle it. Web Server 4D, for example, can be used either as a standalone Web server or as a CGI application alongside another Web server.