Define the Thread Pool Size

When a ClearSCADA server starts, it has to initialize the Alarm Summary, Historic Data, Event Journal, and Configuration Changes stored for your system. To do this, it enumerates all of the granules (files) for each aggregate and stream on disk. It is then able to build indexes for Alarm Summary, Historic Data, Events and Configuration Changes (see Historic Types and Streams).

By default, ClearSCADA initializes the aggregates and streams in groups of 8 (8 aggregates/streams are initialized in parallel). This number is defined by the Thread Pool Size settings in the Server Configuration Tool. There are separate settings for Alarm Summary, Historic Data, the Event Journal, and Configuration Changes.

The Alarm Summary, Historic and Configuration Changes features can each be enabled or disabled. You only need to consider the Thread Pool Size for those features you have enabled on your system.

Larger systems are more likely to benefit from a higher number of threads. This is because large systems take longer to start and often have better hardware than smaller systems. By increasing the Thread Pool Size on a large system, it is possible to improve startup time, in some cases quite significantly. For example, a system with a large database of 250000 historic-enabled points and a high-end storage system could take 90 minutes to start up with Thread Pool Size settings of 8. This could be reduced to as little as 15-20 minutes by increasing the Thread Pool Size for Historic Data to 64.

Similarly, on smaller systems and systems with a single, slow hard disk, reducing the Thread Pool Sizes may improve the server start-up time. However, the effects of increasing or decreasing the Thread Pool Sizes are dependent on your system hardware. Increasing or decreasing the sizes by too much may cause slower startup times.

By experimenting with different Thread Pool Sizes, you will be able to determine the optimum sizes for your specific ClearSCADA system and storage hardware. You can use the Thread Pool Sizesetting to improve the initialization time for the Alarm Summary, Configuration Changes, Event Journal and Historic Data.

To specify the Thread pool size:

  1. Access the ClearSCADA Server Configuration Tool.
  2. Expand the Historic Configuration branch.
  3. Select the historical data type you require, Alarm Summary, Configuration Changes Auditing, Event Journal or Historic Data.

  4. In the Thread Pool Size field, enter the number of aggregates or streams to be initialized in parallel at system start-up.

    We recommend that you experiment with Thread Pool Sizes based on the number of processor cores available. For example, if your hardware has 8 processor cores, try increasing the Thread Pool Size in multiples of 8.

    The range of possible Thread Pool Sizes is 1 - 128 inclusive.

  5. Apply the changes to the server.
  6. Restart the ClearSCADA Server.

We recommend that you perform the following checks after restarting the server:

  1. Access the database startup log file(s). To do this, right-click on the Server icon in the Windows taskbar, and then select the option(s) for the DBStartup log file(s).
  2. In the DBStartup log file(s), search for the following [START] entries and look at the amount of time between them (this time indicates how long it has taken to initialize):

    Alarm Summary

    [START] Initialize Alarm Summary

    Historic Data

    [START] Initialize Historic Data (Step 1)

    [START] Clean Up

    Event Journal

    [START] Initialize Event Journal

    [START] Initialize Configuration - 0%

    Configuration Changes

    [START] Initialize Configuration Change Auditing

    [START] Initialize Event Journal

    Before repeating the test with a different thread pool size, purge the caches in the storage system (operating system, RAID controller, disks and so on). If the caches are not purged, the results of subsequent tests can be distorted significantly.

    In some instances, rebooting the storage system can purge the caches. For more information on how to purge your storage system caches, please refer to the storage system manufacturer or vendor.

    You will see that after the optimum Thread Pool Size has been reached, further increases or decreases will have little effect on the start-up time (or may even cause the start-up to take longer).

  3. Using this information, set the optimum Thread Pool Sizes for your system.

Disclaimer

ClearSCADA 2017 R2