ALTER RESOURCE POOL

Changes the resource settings in an existing resource pool.

Syntax

ALTER RESOURCE POOL pool_name SET (resource_setting [, ...n])
resource_setting:
MEMORY_PERCENTAGE = percent
| QUERY_TIMEOUT = seconds
| SOFT_CPU_LIMIT_PERCENTAGE = percent
| HARD_CPU_LIMIT_PERCENTAGE = percent
| MAX_CONCURRENCY = integer
| MAX_QUEUE_DEPTH = integer

For information on each resource setting, see CREATE RESOURCE POOL.

Remarks

  • You cannot alter the built-in resource pools.

  • CREATE POOL or DROP POOL privileges are required for altering a resource pool.

  • Changes made to a resource pool take effect immediately, but running queries in the pool won’t be killed if the pool currently exceeds its new memory limit.

  • The resource pool settings MEMORY_PERCENTAGE, QUERY_TIMEOUT, SOFT_CPU_LIMIT_PERCENTAGE, HARD_CPU_LIMIT_PERCENTAGE, MAX_CONCURRENCY, and MAX_QUEUE_DEPTH in the resource pools default_pool, system_auto, and system_optimizer_pool are fixed. These settings cannot be changed.

  • This command can be run on a master, or child aggregator (see Node Requirements for SingleStore Commands).

  • Refer to the Permission Matrix for the required permission.

Example

The following example alters resource limits in two resource pools.

Before altering the current limits for the resource pools, it is advisable to set the current limits to a lower value, to create headroom.

ALTER RESOURCE POOL executive SET HARD_CPU_LIMIT_PERCENTAGE = 10;
ALTER RESOURCE POOL general SET HARD_CPU_LIMIT_PERCENTAGE = 10;
ALTER RESOURCE POOL executive SET MEMORY_PERCENTAGE = 10;
ALTER RESOURCE POOL general SET MEMORY_PERCENTAGE = 10;

Now set the new resource limits, as required:

ALTER RESOURCE POOL executive SET HARD_CPU_LIMIT_PERCENTAGE = 75;
ALTER RESOURCE POOL general SET HARD_CPU_LIMIT_PERCENTAGE = 25;
ALTER RESOURCE POOL executive SET MEMORY_PERCENTAGE = 55;
ALTER RESOURCE POOL general SET MEMORY_PERCENTAGE = 45;
  • For more information about using resource pools to specify resource limits, see Set Resource Limits.

Last modified: December 19, 2023

Was this article helpful?

Verification instructions

Note: You must install cosign to verify the authenticity of the SingleStore file.

Use the following steps to verify the authenticity of singlestoredb-server, singlestoredb-toolbox, singlestoredb-studio, and singlestore-client SingleStore files that have been downloaded.

You may perform the following steps on any computer that can run cosign, such as the main deployment host of the cluster.

  1. (Optional) Run the following command to view the associated signature files.

    curl undefined
  2. Download the signature file from the SingleStore release server.

    • Option 1: Click the Download Signature button next to the SingleStore file.

    • Option 2: Copy and paste the following URL into the address bar of your browser and save the signature file.

    • Option 3: Run the following command to download the signature file.

      curl -O undefined
  3. After the signature file has been downloaded, run the following command to verify the authenticity of the SingleStore file.

    echo -n undefined |
    cosign verify-blob --certificate-oidc-issuer https://oidc.eks.us-east-1.amazonaws.com/id/CCDCDBA1379A5596AB5B2E46DCA385BC \
    --certificate-identity https://kubernetes.io/namespaces/freya-production/serviceaccounts/job-worker \
    --bundle undefined \
    --new-bundle-format -
    Verified OK