OS X Server Essentials 10.10: Configuring Open Directory Services
Reference 8.2 Configuring Open Directory Services
To provide the full range of Open Directory services, each server participating in the Open Directory domain, whether a master, replica, or member server, needs to have consistent access to forward and reverse Domain Name System (DNS) records for all the other servers in the domain. You should use Network Utility (or command-line tools) to confirm that DNS records are available.
You use the Server app to configure your server as an Open Directory master or replica, and you use Users & Groups preferences or Directory Utility to bind to another directory server.
Configuring OS X Server as an Open Directory Master
If your server is not already configured as an Open Directory master or connected to another directory service, you can turn on the Open Directory service, and the Server app walks you through configuring your server to be an Open Directory master or replica.
Start by selecting “Create a new Open Directory domain” and clicking Next.
You are prompted to create a new user, with the default name of Directory Administrator and the short name of diradmin.
You are also prompted to provide an organization name and an administrator email address. This organization name will identify this Open Directory server to Mobile Device Management (MDM) systems such as Profile Manager that use it.
Once you confirm these settings, the Server app configures your server as an Open Directory master.
Afterward, the Open Directory pane displays your server, listed as the master. The Server app displays the Internet Protocol version 4 (IPv4) address of each active network interface for each server in the list of Open Directory servers.
You can turn off the Open Directory service by using the switch without destroying the directory configuration. If you need to remove the Open Directory service, selecting the server in the Servers window and then clicking the Delete (–) button at the bottom of the window destroys the configurations permanently.
Creating an Open Directory Archive
When you back up your server with Time Machine, you automatically get a periodic archive of all identification and authorization components of your Open Directory server, including the following:
- The OpenLDAP directory database and configuration files, which include authentication information
- Kerberos configuration files
- Keychain data used by Open Directory
You can also create an Open Directory archive manually. Start by clicking the Action (gear icon) pop-up menu and choosing Archive Open Directory Master.
The next step is to specify a location to create the archive file. Because the archive contains sensitive authentication information, be sure to protect the archive with a secure password.
Once the archive is created, you will find it as a password-protected sparseimage-style disk image.
Configuring OS X Server as an Open Directory Replica
If you already have an Open Directory master on another Mac with OS X Server, you use the Server app to configure your server as a replica of another Open Directory master.
You can configure a server to be a replica by using the Server app on an existing master or replica or by using the Server app on a server you want to configure as a replica. The replica server you’re adding must have remote administration access enabled before you can add it as a replica.
If you’re using the Server app on an existing master or replica, in the Open Directory pane, click the Servers tab, and click Add (+). Then do the following:
- Enter the host name (you could also enter an IP address or local hostname, but this guide recommends using the host name to verify that the crucial DNS host name records are available).
- Enter administrator credentials for the server you want to configure as the replica.
- Choose the parent server.
Enter the directory administrator’s credentials, and click Next.
If, instead, you’re using the Server app on the server you want to configure as an Open Directory replica, select Open Directory in the Server app sidebar. Click the On/Off switch to On, select “Join an existing Open Directory domain as a replica,” and click Next.
In the Parent Server field, enter another Open Directory server’s host name (enter the master’s host name to configure this server as a replica or enter a replica’s host name to configure this server as a replica of the replica), enter directory administrator credentials, and click Next.
Afterward, the Server app displays your server as a replica of the master. In the Open Directory pane’s Servers field, you may need to click the disclosure triangle to view the master and its replica (or replicas). In the following figure, server17 is the master, and server18 is the replica.
If you configure a replica of a replica, or a tier-two replica, the Servers field looks like the following figure, where server19 is a replica of server18, which is a replica of server17.
Configuring OS X Server to Use Another Open Directory Server
If you want your server to simply take advantage of a centralized directory service and not offer directory services itself, you can bind your server to another directory service so users can use credentials hosted by the centralized directory service to access services on your server. This lesson focuses on binding to another Open Directory system.
Use the Users & Groups pane in System Preferences to bind your server to another directory. Open System Preferences, select Users & Groups, select Login Options, and click Join; if the server is already an Open Directory server, click Edit instead of Join.
Enter the host name of an Open Directory server, or click the pop-up menu to browse for one.
When you see the message “This server provides SSL certificates,” click Trust. This adds the Open Directory’s CA, intermediate CA, and SSL certificate to the System keychain so your Mac trusts services that use SSL certificates signed by the intermediate CA.
By default, OS X does not always use SSL when it makes an LDAP connection to an Open Directory server; for many organizations, this is not a concern because the information stored in the LDAP directory is not considered sensitive. Configuring OS X to use SSL for LDAP is outside the scope of this guide.
When you see the Client Computer ID window, leave the Client Computer ID field, which is generated from your host name, as it is.
You have the option to bind anonymously or set up authenticated binding.
Anonymous binding is appropriate when binding with OS X clients, but you should use authenticated binding, which mutually authenticates the member OS X Server and the Open Directory service, when binding a server to an Open Directory server. An authenticated bind creates a computer record in the Open Directory service; this computer record is used to mutually authenticate the bind between the two servers.
As an alternative, you can use Directory Utility or the command-line environment because they offer some advanced binding options, especially if you’re binding to an Active Directory node.
Using Directory Utility Remotely
You can still use Directory Utility instead of System Preferences; in fact, using Users & Groups preferences offers a shortcut to Directory Utility, which is located in /System/Library/CoreServices/Applications/. Directory Utility offers more control than the Join button of Users & Groups preferences when binding to a directory service, and it allows you to make changes to a remote computer’s directory services from OS X.
Binding OS X to Your Open Directory Service
Once you have an Open Directory master (and perhaps one or more replicas) set up, you can also configure the client computers to bind to the directory service so your client computers can take advantage of Open Directory services. On each client computer, you use Users & Groups preferences to specify a server that hosts an Open Directory service, or if you need more-advanced binding options, you use Directory Utility to create an LDAP configuration that has the address and search path for an Open Directory server.