Sun ONE logo     Previous      Contents      Index      Next     
Sun ONE Directory Server 5.2 Installation and Tuning Guide



Chapter 3   Top Tuning Tips

Tuning performance implies modifying the default configuration to reflect specific deployment requirements.

This guide describes how to tune a single Directory Server instance. It is assumed here that your overall directory service design including the replication topology is complete, and that you use the information here to tune the Directory Server instances to meet the design requirements. If you have not yet completed the overall directory service design, refer to the Sun ONE Directory Server Deployment Guide for suggestions on how to do so.

Tuning performance takes time, effort, and thought as reflected in Table 3-1.

Table 3-1    Tuning Process 

Phase

Description

Define goals

Define specific, measurable objectives for tuning, based on deployment requirements. Consider questions such as:

  • Which applications use Directory Server?
  • Is the system dedicated to Directory Server? Does it run other applications? If so, which other applications?
  • How many entries does the deployment call for? How large are such entries?
  • How many searches per second must the Directory Server support? What types of searches are expected?
  • How many updates per second must the Directory Server support? What types of updates are expected?
  • What sort of peak update and search rates are expected? What sort of average rates are expected?
  • Does the deployment call for repeated bulk import initialization on this system? If so, how often are imports performed? How many entries are imported at a time? What types of entries? Must initialization be performed online with the server running?

This list is not exhaustive. Ensure yours is.

Select methods

Determine how you plan to implement tuning optimizations and how you plan to measure and analyze them.

Can you change the hardware configuration of the system? Are you limited to using existing hardware, tuning only the underlying operating system and Directory Server itself? How can you simulate other applications? How should you generate representative data samples for testing? How should you measure results? How should you analyze results?

Perform tests

Carry out the tests planned. For large and complex deployments, this phase may take considerable time.

Verify results

Check whether the potential optimizations tested reach the goals defined at the outset of the process.

If they reach the goals, document the results.

If they do not reach the goals, profile and monitor the Directory Server you are tuning.

Profile and monitor

Profile and monitor the behavior of Directory Server after applying the potential modifications. Collect measurements of all relative behavior.

Plot and analyze

Plot and analyze the behavior observed while profiling and monitoring. Attempt to find evidence and patterns that suggest further tests.

You may need to go back to the profiling and monitoring phase to collect more data.

Tweak and tune

Apply further potential optimizations suggested by your analysis of measurements.

Return to the phase of performing tests.

Document results

Once the optimizations applied reach the goals defined at the outset of the process, document them well so they can be easily reproduced.

This chapter lists basic recommendations that apply almost every time you tune a Directory Server instance. Although the recommendations presented here are in general valid, avoid the temptation to apply them without understanding how they impact the specific deployment at hand. This chapter is intended as a checklist, not a cheat sheet.

  1. Adjust cache sizes.
  2. Ideally, the server has enough available physical memory to hold all caches used by Directory Server. In that case, set the entry cache size large enough to hold all entries in the directory, and set the database cache size large enough to hold all indexes.

    Refer to Chapter 6 "Tuning Cache Sizes," for more information.

  3. Optimize indexing.
    1. Remove unnecessary indexes and add additional indexes to support expected requests.
    2. From time to time, it may become necessary to add additional indexes that support requests from new applications. It is possible to add, remove, and modify indexes while Directory Server is running, with the limitation that existing data are only indexed progressively from that point forward.

      Refer to "Benefits: How Searches Use Indexes" and "Costs: How Updates Affect Indexes" for more information.

    3. Allow only indexed searches.
    4. Unindexed searches can have a strong negative impact on server performance and may consume significant server resources. Consider adding indexes to support specific searches applications may perform, and forcing the server to reject unindexed searches.

      Refer to "Allowing Only Indexed Searches" for more information.

    5. Adjust the maximum length of index lists.
    6. Refer to "Limiting Index List Length" for more information.

  4. Tune the underlying operating system.
  5. Refer to Chapter 5 "Tuning the Operating System," for more information.

  6. Adjust operational limits.
  7. Adjustable operational limits prevent Directory Server from devoting inordinate resources to any single operation. Consider assigning unique bind DNs to client applications requiring increased capabilities, then setting resource limits specifically for these unique bind DNs.

    Refer to Chapter 9 "Managing Use of Other Resources," for more information.

  8. Disable unnecessary logging.
  9. Disk access is much slower than memory access. Writing frequently to log files on disk can have strong negative impact on performance. If possible, eliminate disk writes by turning access, error, and audit logging off when not required. At minimum, attempt to reduce the impact of logging by putting log files on separate disks using separate controllers.

    Refer to Chapter 8 "Tuning Logging," for more information.

  10. Distribute disk activity.
  11. Especially for deployments supporting large numbers of updates, Directory Server can be extremely disk I/O intensive. If possible, consider spreading the load across multiple disks using separate controllers.

    Refer to "Sizing Disk Subsystems" for more information.


Previous      Contents      Index      Next     
Copyright 2003 Sun Microsystems, Inc. All rights reserved.