Skip to main content

oh cluster

Manage compute clusters.

Cluster types: Managed SQL Spark Open_Engines Notebook LakeBase


oh cluster show

Lists all clusters.

oh cluster show

oh cluster describe NAME

Describes a single cluster.

oh cluster describe prod

oh cluster create NAME

Creates a new cluster.

Flags

FlagRequiredDescription
--typeYesCluster type: Managed, SQL, Spark, Open_Engines, Notebook, LakeBase
--max-ocu INTNoMaximum OCU limit. Required for all types except LakeBase.
--min-ocu INTNoMinimum OCU limit. Required for all types except LakeBase.
--options KEY=VALUENoWITH clause parameters; repeatable (see Special parameters)

Special parameters

All WITH clause parameters from the CREATE CLUSTER API are passed via --options KEY=VALUE.

ParameterDescription
worker.typeWorker instance type (e.g., oh-general-4)
worker.spotTrue or False — enable spot instances for workers
driver.typeDriver instance type. Default is Auto (same as workers)
quanton.enabledtrue or false — enable Quanton engine. Valid for SQL, Spark, Notebook only
open_engines.engineTrino, Flink, or Ray. Required for Open_Engines type
open_engines.catalogCatalog name for Trino/Flink clusters. Required for Trino
open_engines.ray.max_cpu_unitsMax CPU units for Ray clusters
open_engines.ray.min_cpu_unitsMin CPU units for Ray clusters
open_engines.ray.max_gpu_unitsMax GPU units for Ray clusters
worker.gpu_typeGPU worker instance type (e.g., oh-gpu-4). Ray clusters only
attached_storage.driver_storage_sizeDriver attached storage in GB (AWS only)
attached_storage.worker_storage_sizeWorker attached storage in GB (AWS only)
ocu.notifications.enabledTrue or False — OCU usage notifications. Default True
ocu.notifications.thresholdPercentage of max OCU that triggers a notification. Default 80
lakebase.engine_sizeEngine size for LakeBase clusters: 2x-small, x-small, small, medium, large, x-large, 2x-large, 3x-large, 4x-large
lakebase.min_enginesMinimum number of Spark clusters always running (LakeBase only)
lakebase.max_enginesMaximum number of Spark clusters (LakeBase only)
catalog.nameCatalog name (LakeBase only). Defaults to the Onehouse catalog
catalog.permissions_enforcementnone (default) or lake_formation (LakeBase only)

Examples

Managed cluster

oh cluster create prod \
--type Managed \
--max-ocu 20 \
--min-ocu 2 \
--options worker.type=oh-general-4 \
--options driver.type=oh-general-8 \
--options ocu.notifications.enabled=True \
--options ocu.notifications.threshold=75

Spark cluster with spot workers

oh cluster create jobs-prod \
--type Spark \
--max-ocu 10 \
--options worker.type=oh-general-8 \
--options worker.spot=True

Trino Open Engines cluster

oh cluster create trino-prod \
--type Open_Engines \
--max-ocu 10 \
--min-ocu 1 \
--options worker.type=oh-general-4 \
--options open_engines.engine=Trino \
--options open_engines.catalog=my-glue-catalog

Ray Open Engines cluster (with GPU)

oh cluster create ray-prod \
--type Open_Engines \
--max-ocu 10 \
--min-ocu 1 \
--options worker.type=oh-general-4 \
--options worker.gpu_type=oh-gpu-4 \
--options open_engines.engine=Ray \
--options open_engines.ray.max_cpu_units=7 \
--options open_engines.ray.min_cpu_units=1 \
--options open_engines.ray.max_gpu_units=3

LakeBase cluster

oh cluster create lakebase-prod \
--type LakeBase \
--options lakebase.engine_size=medium \
--options lakebase.min_engines=1 \
--options lakebase.max_engines=5 \
--options catalog.name=my-glue-catalog \
--options catalog.permissions_enforcement=lake_formation

oh cluster alter NAME

Alters an existing cluster. Supply any combination of flags.

Flags

FlagDescription
--stateSTART or STOP
--max-ocu INTNew maximum OCU
--min-ocu INTNew minimum OCU
--new-nameRename the cluster
--options KEY=VALUEWITH clause parameters; repeatable (see Special parameters)

Special parameters

Uses the same parameter keys as create, with the following available for alter:

ParameterDescription
worker.typeNew worker instance type
worker.spotTrue or False
driver.typeNew driver instance type
quanton.enabledtrue or false
open_engines.ray.max_cpu_unitsNew max CPU units (Ray clusters)
open_engines.ray.min_cpu_unitsNew min CPU units (Ray clusters)
open_engines.ray.max_gpu_unitsNew max GPU units (Ray clusters)
attached_storage.driver_storage_sizeNew driver storage in GB (AWS only)
attached_storage.worker_storage_sizeNew worker storage in GB (AWS only)
lakebase.engine_sizeNew engine size (LakeBase only)
lakebase.min_enginesNew minimum engines (LakeBase only)
lakebase.max_enginesNew maximum engines (LakeBase only)

Examples

# Scale up a Managed cluster
oh cluster alter prod --max-ocu 40 --min-ocu 4

# Stop a cluster
oh cluster alter prod --state STOP

# Rename a cluster
oh cluster alter prod --new-name prod-v2

# Update Ray cluster compute limits
oh cluster alter ray-prod \
--max-ocu 8 \
--min-ocu 2 \
--options open_engines.ray.max_cpu_units=5 \
--options open_engines.ray.min_cpu_units=2 \
--options open_engines.ray.max_gpu_units=3

# Resize a LakeBase cluster
oh cluster alter lakebase-prod \
--options lakebase.engine_size=large \
--options lakebase.min_engines=2 \
--options lakebase.max_engines=10

oh cluster delete NAME

Deletes a cluster.

oh cluster delete prod