Free at 3:00? Let Outlook Answer
In Exchange Server deployments, calendars are probably the most-used feature, next to email. One component that facilitates scheduling in calendars is free/busy data. To support the use of free/busy data, you need to know how Outlook's various scheduling mechanisms use that data. You also need to know how free/busy data is stored and updated. Armed with this knowledge, you can troubleshoot and resolve scheduling problems that arise.
How Scheduling Mechanisms Use Free/Busy Data
When an organizer is scheduling a meeting, the organizer needs to know when all the meeting invitees have the same block of free time. One way to find a common block of free time is to look at each invitee's calendar, which means the organizer must meet two conditions: authentication and access. Authentication is necessary to validate the organizer's account so that the system hosting the invitee's calendar knows whether to allow access to the schedule. One or more account domains hosting the organizer's and invitees' accounts handle the authentication. In Exchange Server 5.5 deployments, sites might span account domains and those domains might not have a trust relationship between them. The lack of a trust relationship prevents Exchange from authenticating organizers in other sites who are trying to view an invitee's calendar. (The transitive nature of Active Directory--AD--trusts eliminates this problem in Exchange Server 2003 and Exchange 2000 Server deployments.)
Even when a Windows NT 4.0 or an AD trust exists between domains, the access condition must still be met. To see another person's schedule, the calendar owner must grant at least Reviewer permission. Because the default permission to calendars is No access, the calendar owner must manually change this permission. Thus, an organizer might not be able to access invitees' calendars because the invitees don't know how to grant access to others. In addition, some people are reluctant to make their calendars publicly visible because they might contain personal or sensitive information.
To work around these problems, Exchange provides another view of a person's calendar--a map that specifies when a person is free or busy. This free/busy map is stored in such a way that it's accessible to anyone in the Exchange organization (more about this later). For example, take a look at Figure 1. On the left side is a day from a calendar, as you'd see it in Outlook. The right side shows a representation of what the various types of appointments scheduled for that day might look like if you were to view the free/busy map. When a meeting organizer wants to invite a person to a meeting, Outlook's scheduling tool looks at the invitee's free/busy map to determine whether the proposed meeting time is available.
Another Outlook feature that uses free/busy data is direct booking, which Outlook 2000 first introduced. This feature lets you reserve resources, such as conference rooms, without the need for a delegate to accept the reservation request. Direct booking uses the free/busy map to determine whether a resource is available. (For more information about direct booking, see "Using and Configuring Outlook Direct Booking," October 2002, InstantDoc ID 26184.)
How Free/Busy Data Is Stored
Free/busy data differs from the appointment data it represents in a couple of ways. First, when you create an appointment in your calendar, you assign attributes such as the time and topic of the appointment and the attendees' names. The appointment can even include attached items, such as a Microsoft PowerPoint presentation. The free/busy map doesn't include any details about the appointment. The map just contains one of four possible time-usage categories--Free, Busy, Out of Office, and Tentative--that generically define how that block of time is being used.
Second, unlike appointments, the free/busy map resides in a public folder. As the name implies, access to public folders isn't restricted in the same way that access is restricted to an individual's calendar. Anyone who can access the public folder can read and use its contents. Public folders can also be replicated to servers in other routing groups (Exchange 2000 and later) or to servers in other sites (Exchange 5.5). The replication lets meeting planners in all parts of the organization easily and efficiently access free/busy data.
In the public folder store, free/busy data is organized as a hierarchy of public folders. At the root level, the public folders are organized into two subtrees: IPM_SUBTREE and NON_IPM_SUBTREE. (IPM is short for interpersonal message.) IPM_SUBTREE is a visible subtree that contains the folders you can see when you expand the Public Folders directory in Outlook. NON_IPM_SUBTREE is a hidden subtree that contains folders the system uses to implement special features, such as the free/busy map.
The first folder in NON_IPM_SUBTREE is Schedule+ Free Busy. This folder contains a set of child folders, one for each administrative group (Exchange 2000 and later) or Exchange site (Exchange 5.5). To see the path for an administrative group's free/busy folder, you can use Exchange System Manager (ESM). Right-click the administrative group, select Properties, and click the General tab in the Properties dialog box. The path to that administrative group's free/busy folder will be in the Path field. For example, the path for the free/busy folder for the First Administrative Group in my Exchange deployment is /NON_IPM_SUBTREE/SCHEDULE+ FREE BUSY/EX:/o=NEULAN/ou=First Administrative Group/. The portion in italics specifies the free/busy folder's name. Although the slashes make it seem as if there are intermediate folders named EX: and o=NEULAN, everything from EX: on makes up the name of the free/busy folder.
Besides ESM, you can use Exchange's Mdbview utility to see all the folders in NON_IPM_SUBTREE. Using this utility, you can also see that each administrative group's or site's free/busy folder holds a set of free/busy messages that store the free/busy data. Each message represents one mailbox and contains binary code that represents each appointment's time-usage category. Using Collaboration Data Objects (CDO) 1.2 or later, you can query Exchange for the free/busy information for a specific date and time period in specified time increments. For example, you can retrieve the free/busy data for Wednesday, April 7, between 11:30 a.m. and 5:30 p.m. in 30-minute increments. The query returns a coded string that represents the time-usage categories, in which each digit in the string represents the time increment you requested. In this string, the value of 0 represents Free, 1 represents Tentative, 2 represents Busy, 3 represents Out of Office, and 4 represents No data available. So, if you use Figure 1 as a reference, the April 7 query just given would return the string 113333332220. If you had made the same query but requested 15-minute increments, the string returned would be 111133333333333322222200. (For more information about retrieving free/busy data, see the Microsoft article "How To: Check Someone Else's Schedule for Free/Busy Information" at http://support.microsoft.com/?kbid=186753.)
Exchange doesn't store a separate state code for every minute of the day. Instead, for storage efficiency, Exchange groups similar state codes together into blocks and stores information about each block's size and state. The number of blocks needed to represent the free/busy time depends on the number of state transitions, not on the number of appointments. For example, the calendar in Figure 1 has six appointments with blocks of free time before and after them. You might assume that there are eight blocks if you count the six appointments and include the two blocks of free time. However, the two appointments between 8:30 a.m. and 11:30 a.m. are both defined as Busy. Because they're contiguous, they're represented as a single block in a free/busy map. The same holds true for the lunch and dentist appointments between 12:30 p.m. and 3:30 p.m. They're treated as a single block of Out of Office time. Thus, there are five transitions between six blocks: Free, Busy, Tentative, Out of Office, Busy, and Free.
By storing free/busy data as blocks of consecutive time instead of representations of individual appointments, the amount of storage needed for the free/busy map is minimal. A completely blank schedule uses about 240 bytes. Each state change adds 4 bytes, so the six free/busy blocks in this example would use only 264 bytes of public folder storage.
How Free/Busy Data Is Updated
Free/busy data is updated when a client such as Outlook or Outlook Web Access (OWA) makes a change to a calendar. For example, when you create an appointment or accept a meeting invitation, your calendar changes and the client updates the free/busy data to reflect your availability. The map isn't updated in the sense that free/busy information from a new appointment is integrated into the existing map. Each time the client updates the free/busy map, the map is completely regenerated. The client stores the free/busy map in a hidden message called LocalFreebusy. The client then copies the map data from the LocalFreebusy message into the appropriate free/busy folder in the public folder store, again replacing any previous map.
By default, all versions of Outlook are configured to publish 2 months of free/busy data. With Outlook XP and later, you can publish up to 36 months of free/busy data. In earlier Outlook versions, you can publish only up to 12 months of data. You configure the number of months to publish in the Free/Busy Options dialog box, which Figure 2 shows. To access this dialog box, open Outlook, select Options under the Tools menu, and choose the Preferences tab. Click Calendar Options, then Free Busy Options.
The LocalFreebusy message's 0x6869 property stores the number of months of free/busy data to publish (i.e., the publication interval). Figure 3 shows this property in Mdbview. The sidebar "Viewing the LocalFreebusy Message in Mdbview" explains how you can access this message. In this example, 36 months of data are to be published. When a client such as OWA updates free/busy data, it reads this property to know how many months of free/busy data to generate.
Understanding where free/busy data is stored becomes important when you need to troubleshoot problems. Because the clients, not the Exchange server, generate free/busy maps, clients with different publication intervals can sometimes cause confusion for shared and delegated calendars. Free/busy data is generated when any client with write access to a calendar makes a change. For example, suppose an administrative assistant is delegated access to a supervisor's calendar. When the delegate accepts a meeting invitation on behalf of the supervisor, the delegate's Outlook client generates a new version of the supervisor's free/busy map. Similarly, when you use Outlook's direct booking feature to book a resource (which requires write access to the resource you're attempting to book), your copy of Outlook generates a new version of the resource's free/busy map. The number of months of free/busy data generated is based on the free/busy publication interval for the Outlook client being used, not on the value stored in the mailbox's LocalFreebusy item. Thus, problems arise when people use Outlook with different publication intervals. For example, suppose one user has Outlook 2000 and another user has Outlook 2003. The Outlook 2000 user can publish only 12 months of data, whereas the Outlook 2003 user can publish 36 months of data. The amount of free/busy data available at any given time depends on who updated the map last.
To illustrate the problem that can result from different publication intervals, let's look at Outlook's direct booking feature. Suppose it's September and Emily uses direct booking to successfully reserve a conference room between 2:00 p.m. and 5:00 p.m. on December 16, 2004. Emily has configured Outlook to publish 12 months of free/busy data, so her Outlook client generates a conference room free/busy map that spans from September 2004 through August 2005. The next day, Ed successfully books the conference room for all day on October 1. Ed's Outlook client is still configured with the default publication interval of 2 months, so his Outlook client generates a conference room free/busy map that spans only from September through October. This new map replaces the map posted by Emily's Outlook client. Thus, all the Free, Busy, Tentative, or Out of Office entries in the other 10 months (November 2004 through August 2005) no longer exist. If no free/busy data exists (i.e., a state code of 4), direct booking assumes that the time is available. Now if another person tries to reserve the conference room from 2:00 p.m. to 3:00 p.m. on December 16, 2004, the booking will be successful and the conference room will be double-booked during that time.
One way to deal with this problem is to configure every Outlook client to publish the same number of months of free/busy data. The Microsoft article "XCLN: How to Configure Default Free/Busy Options" (http://support.microsoft.com/?kbid=197712) describes the registry keys that store the publication interval. This article was written a while ago, so it doesn't give information for newer versions of Outlook. The registry keys in Outlook XP (and later) are the same as those in Outlook 2000. In addition, although the article states that the maximum number of months is 12, the upper limit is now 36 for Outlook XP and later. No matter the Outlook version, the publication interval must be in hexadecimal form (e.g., 0x0C for 12 months, 0x18 for 24 months).
The choice of which publication interval is best for you depends on your environment. Before choosing the publication interval, one of my customers wanted to know how the publication interval would impact storage space in its Exchange enterprise. The customer had more than 22,000 Exchange mailboxes, 11,616 of which published free/busy maps. In the largest administrative group, there were about 2800 mailboxes, 2577 of which published free/busy maps. (About 450,000 appointments were spread over those 2577 mailboxes, so as you might have guessed, this customer was in the government sector.)
To begin, I decided to determine how much storage space the free/busy data typically consumed based on the number of months published. So, I used a script to examine the LocalFreebusy message for the 2577 mailboxes in the largest administrative group. Table 1 shows the results. On average, the 2577 mailboxes used 2.3MB of storage space for the free/busy maps.
Using the information in Table 1 as a basis, I then estimated the storage utilization if the customer were to standardize the publication interval at 12 months, 24 months, and 36 months. As Table 2 shows, publishing 12 months of free/busy data would use only about 5MB of storage. Even publishing 36 months of free/busy data wouldn't overtax storage space.
After you decide on a standardized publication interval for your Exchange enterprise, you can use AD Group Policy Objects (GPOs) to apply it. When you change the setting, keep three items in mind. First, although "XCLN: How to Configure Default Free/Busy Options" specifies that the maximum number of months is 12, the upper limit is 36 for Outlook XP and later. Second, your maximum publication interval will be governed by your oldest client. Third, don't forget to translate the months into hex form.
Troubleshooting Problems with the Free/Busy Map
The problems I've encountered with the free/busy map mainly relate to the amount of free/busy data published. As I just described, different settings in clients can result in different amounts of data being published. To troubleshoot this problem, you need a way to determine who is publishing fewer months than expected.
Using Mdbview, you can open the public folder store and view the raw properties of a mailbox's free/busy data. As Figure 4 shows, PR_LAST_MODIFIER_NAME is one of these properties. (In older Mdbview versions, the property's name might be 0x3FFA. The version I used at the time of writing this article was 6.5. You can obtain the latest Mdbview version from the Microsoft Download Center at http://www.microsoft.com/downloads. Search using the keyword mdbvu32.) This property holds the name of the account that last generated the free/busy data. After you know who generated the data, you can use Mdbview to access that person's LocalFreebusy message, assuming you have adequate rights to access the mailbox. By examining the 0x6869 property, you can determine whether the person is publishing fewer months than expected. If so, you can then help the person update his or her Outlook client to publish more months of data.
Another common problem is a lack of free/busy data for a particular administrative group or site. When a client needs to access free/busy data, it first checks the local server's public folder store for the data. If unsuccessful, the client tries a server in its routing group, then expands to servers in other routing groups until it finds a public folder store with a copy of the data.
In cases in which an administrative group's free/busy folder has been replicated, the free/busy message might not have been replicated to the public folder stores that are being checked by the client. With the OWA versions in Exchange 2003 and Exchange 2000, you can use Web queries to check servers' public folder stores for free/busy maps. You can query each server in which replicas should be found to see which one doesn't have the free/busy map.
Here's how Web queries work: From Microsoft Internet Explorer (IE), you use a URL to query a specific public server's public folder store for a free/busy map. For example, the URL http://SRV3/public/?cmd=freebusy&start=2007-02-14T00:00:00-05:00&end=2007-02-14T23:59:00-05:00&interval=30&u=SMTP:email@example.com queries the public store on the SRV3 server. The cmd= parameter specifies that you want to check for free/busy data. The u=SMTP: parameter specifies the account to check. The start=, end=, and interval= parameters define the range of free/busy information to return. The Microsoft article "XCCC: Description of the Command to Retrieve Free/Busy Information From a Calendar Public Folder" (http://support.microsoft.com/?kbid=813268) describes exactly how to format queries.
The Web query produces an XML data page that contains a series of tags. You need to look for the <a:fbdata> tag. If a free/busy map is present, the tag might look something like <a:fbdata>000000000000000000000000111333333000000000000000</a:fbdata>. If a free/busy map isn't present, the <a:fbdata> tag will contain all 4s.
Effectively Support Your Users or Customers
You rarely find anyone in the business world whose days and plans aren't affected in some way by the necessity of meeting with other people. Scheduling free/busy information is a crucial component for effective use of Exchange calendars. By understanding where and how free/busy map information is stored and generated, you'll be much better equipped to support your users or customers.