Global Variables

Caution

You can set a sync variable on the Master Aggregator only. You will receive an error if you attempt to set a sync variable on any other type of SingleStore node.

You should not set a sync variable by editing the memsql.cnf file. Attempting to do so may result in an error, or the setting may have no effect. Instead, set sync variables using methods described here.

For advanced users, a globalVariables section can also be declared. This is an optional section that allows values to be specified for SingleStore engine variables.

...
globalVariables:
snapshots_to_keep: "6"
transaction_buffer: "8m"
default_partitions_per_leaf: "4"

Refer to Engine Variables and List of Engine Variables documentation for more information about engine variables, global variables, and when to use them.

As of Operator 1.2.1, nearly all engine variables are supported except for:

  • bottomless_storage_location

  • cloud_permissions

  • cluster_name

  • enable_bottomless

  • enable_sites

  • expected_leaf_core_count

  • redundancy_level

  • sync_permissions

Note that some engine variables can be set prior to deploying a new cluster, but cannot be set once the cluster is running.

  • SYNC variables may be set at launch of a new cluster. Once the cluster is online and running, these variables must then be set through a database connection.

  • NON-SYNC variables may be set in the globalVariables section of the MemsqlCluster spec.

Refer to the List of Engine Variables for more information.

Note

If it is not overridden in the globalVariables section, the Operator will set default_partitions_per_leaf to a value equal to the height multiplied by the vCPU cores per unit.

Both aggregatorSpec and leafSpec-specific globalVariables sections may be declared. The optional spec.aggregatorSpec and spec.leafSpec sections in the sdb-cluster.yaml file allow non-sync variables for aggregators and leaf nodes to be specified separately.

aggregatorSpec:
...
globalVariables:
snapshots_to_keep: "4"
...
leafSpec:
...
globalVariables:
snapshots_to_keep: "5"

Once the sync and non-sync variables are set via spec.globalVarialbes, they are applied across the entire cluster.

  • All variables set via spec.aggregatorSpec.globalVariables are applied to all pods in Master Aggregator and child aggregators.

  • All variables set via spec.leafSpec.globalVariables are applied to all pods in leaf nodes.

Include only non-sync variables in spec.aggregatorSpec.globalVariables and spec.leafSpec.globalVariables.

Non-sync variables defined in spec.aggregatorSpec.globalVariables and spec.leafSpec.globalVariables override the same variables defined in spec.globalVariables.

Last modified: August 17, 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