Reindexing the CAM Database

 This topic applies to on-premises installations.

To speed up the retrieval of data from the CAM Database, you may want to periodically reindex it. To do so, select Reindex Database from the Tools menu in CAM Administrator. Read on for details about the reindexing process and how often you should reindex the CAM Database.

As data is added, SQL Server adds indexes to where the data is stored. Later, when SQL Server needs to look up this data, it can search the index to find the data. However, the indexes might not be created for optimal performance in retrieving data, so you may want to improve this performance by reindexing the CAM Database. Reindexing reorders the indexes so as to speed up data retrieval.

As you run initial inventories on the machines in your network, large amounts of data are added to the CAM Database, so it's a good idea to reindex the CAM Database often at these times (daily if possible, or once a week). After most first-time inventories are completed, you don't need to reindex the CAM Database as often.

The best time to reindex the CAM Database is during off hours when new data is not being written to it. By default, Cherwell Asset Management runs a scheduled task that reindexes the CAM Database every Saturday morning at 1:00 a.m. This setting should be adequate in most cases and if it works in your organization, you won't need to reindex the database manually from the Tools menu.

If your site is a large one where a lot of machines were recently inventoried, or if you enable metering for a large number of applications, you may want to reindex the database daily for the first week to improve performance. Even then, you really only need to reindex the database if users complain about slow application launches, or if reports time out or take an unusually long time to display.

For optimal performance, metering only the applications you want to closely monitor is recommended.

The length of time it takes to reindex the CAM Database depends on variables like computer speed, available memory, and the amount of data stored in the CAM Database. Typically, reindexing completes in less than one minute, but can take as long as 15 minutes. During this time, SQL Server may be unresponsive to requests for data input and output to the CAM Database, which may cause CAM Agents to temporarily go into offline mode and cache their data. When a CAM Agent goes offline, the next launch can take an extra five seconds or so. When a CAM Agent is offline, it caches data and subsequent offline launches are not delayed. Offline CAM Agents create a small amount of additional overhead on the network, as data has to be sent twice. The additional network overhead is only an issue if data is sent over a slow link and even then, the amount of additional overhead is very small.

Even under optimal conditions, a few reports (the Am I Compliant and the peak usage reports) can take a long time to display. Depending on filter settings and whether a peak usage report was recently run, these reports may need to generate peak usage data at report creation time.