User’s Guide

NetTime for Macintosh

Author: 	David E. Catlett (davidcat@microsoft.com)

Date:	18 March 1996

Revision: 	0.2

Overview

This help file is broken in to two sections: A brief description of NetTime and why it is useful, and details on how to modify it to point to a server on your network.

NetTime: A brief overview

NetTime came out of a need to quickly synchronize the local Macintosh clock to a known good clock on the AppleTalk network. There are several reasons this is useful, but particularly in the scenario of testing an AFP-compliant server, it is good to have all the Macs that are testing the server have the same time as the server so error logs with time stamps on the local Mac can be aligned with error logs on the server.

Another reason is that traditionally the Mac has had the reputation of having a clock that easily gets off. I don't know if that’s true of the latest Macs, but it seems to have created quite a legend among the Mac community. In the case of those who believe such statements about the Macintosh clock, this application will ease your nerves and allow you to synchronize with a known good clock from an AFP server on the network. The server can be a Windows NT Services for Macintosh server, or any AppleShare server on your network that allow guest access.

Technically speaking it simply opens a session to the server, logs on as guest, does a GetSrvrParms, parses out the server time, does some calculations to format it the way the Macintosh stores it and sets the local clock. Pretty simple. Because of the nature of the computations necessary and the possibility of network traffic interference, your local Mac clock will not be exactly synchronized, but it should be within five seconds of the AFP Server.

I’ve enlisted the aid of Apple’s AFP C++ classes and used Symantec C++ for the Macintosh to create and compile the application. It is a 68K app.

NetTime Setup

As stated above, NetTime uses an AppleShare server to synchronize the local Mac clock. In order to point it at your AppleShare server, you will need to use a resource editor such as ResEdit to modify the some ‘STR’ resources.

Here are step-by-step instructions on modifying NetTime so it will synchronize your local Macintosh clock with your AFP server on your AppleTalk network using ResEdit:

1. Launch ResEdit

2. From File menu, choose Open…

3. Locate NetTime and click Open

4. Find the ‘STR’ resource and double-click with the mouse. Located in the STR resource are four (4) ID’s, 128-131, with names of “Zone”, “Server”, “Alt Zone” and “Alt Server” (see Figure 1).

1. 	Figure 1

5. Double-click on “Zone” and type in the zone where your server is located. If your network doesn’t have a zone listing, type in an asterix: *. You do not need to put anything in the Data$ edit box. Now close the window.

6. Open the “Server” ID and type in the name of your AppleShare server. Again, you don’t need to put anything in the Data$ edit box. Now close the window.

The “Alt Zone” and “Alt Server” can also be edited as well with another server. NetTime will first use the server in “Server” in the zone in “Zone” and if it can’t find the server, it will try to find the “Alt Server” in the “Alt Zone.”

If NetTime cannot find either server, it will present a dialog telling you just that and recommending that you modify the STR resources accordingly.

My suggestion is to place NetTime in your Startup Items folder in the System Folder, so that each time your Mac starts up, it’s clock will be synchronized with the AppleShare server.

Modification History

Date	Done By	Comment

1/26/96	DavidCat	Original Version

3/18/96	DavidCat	Added Screen Shots for ResEdit