Enabling random chunk distributions
You can enable random distributions that skew the storage for a table to one or a few extents.
About this task
The system.enableRandomDistributionChunkSize system registry variable enables or disables the random chunk distribution feature at the system-wide level. If the value of the system.enableRandomDistributionChunkSize registry variable is yes or on and users specify DISTRIBUTE ON RANDOM when creating tables, the system uses random chunk distribution to store records for the tables. The default value of the system.enableRandomDistributionChunkSize registry variable is no (off).
Depending on the approach that you use, you can enable the random chunk distribution feature temporarily or you can enable it so that it remains in effect after a NPS system restart. To enable the feature temporarily, you must be the admin user or your database account must have permissions to manage the system.
Procedure
- To enable the feature temporarily, perform the following steps:
- Pause the system by issuing the following command:
nzsystem pause
- Set the value of the system.enableRandomDistributionChunkSize registry
variable to yes or on by issuing the nzsystem set
-arg command. An example follows:
nzsystem set -arg system.enableRandomDistributionChunkSize=yes
- Resume the system by issuing the following command:
nzsystem resume
- Pause the system by issuing the following command:
- To enable the feature so that it remains in effect after a NPS system restart, perform the
following steps:
- Log in to the system as the root user.
- Using a text editor such as vi, edit the /nz/data/config/system.cfg file.
- Set the value of the system.enableRandomDistributionChunkSize registry
variable to yes or on. An example follows:
system.enableRandomDistributionChunkSize = yes
- Save and close the system.cfg file.
What to do next
To disable the random chunk distribution feature, you can use the previous steps but
set the system.enableRandomDistributionChunkSize registry variable to
off or no or remove the variable from the
system.cfg file. Alternatively, you can set the
enable_random_dist_chunk session variable to no or
off (for example, specify set enable_random_dist_chunk = no
) to
disable the random chunk distribution feature at the session level. The default value of the
enable_random_dist_chunk session variable is yes
(on). If the value of the
system.enableRandomDistributionChunkSize registry variable is
no or off, setting the
enable_random_dist_chunk session variable to yes or
on has no effect.