Dan Newton
04/01/2026, 2:45 PMstorageVolume configuration is not specified. Furthermore, is it possible to change the assigned disk size without assigning it a pvc?Rocky
04/01/2026, 2:46 PMstorageVolume (or storageVolumes in the CRD) configuration is not specified for CN nodes, the StarRocks Operator does not create a Persistent Volume Claim (PVC). Instead, it defaults to using an emptyDir volume for the CN's storage (including logs and local cache).
* Default Size: The size of an emptyDir volume is not fixed by the operator. It is limited by the available space on the Kubernetes node's disk (specifically the filesystem where the kubelet's root directory, typically /var/lib/kubelet, is located).
* Behavior: Because CN nodes are designed to be "stateless" or use storage primarily for query caching, the emptyDir allows them to scale up and down quickly without managing persistent state.
2. Changing Disk Size Without a PVC
Yes, it is possible to change or limit the assigned disk size for CN nodes without using a persistent PVC (i.e., without persistent storage that survives pod deletion). You can do this in two ways:
* Using emptyDir with a `sizeLimit`:
While the StarRocks Operator primarily focuses on PVC-based storageVolumes, you can sometimes influence this through the storageVolumes configuration by specifying a storage class that provides ephemeral local storage. However, the most direct way in Kubernetes is to set a sizeLimit on the emptyDir. In the StarRocksCluster CRD, you can define storageVolumes but omit the storageClassName (which would use the default) or use a specific "ephemeral" storage class if your cluster supports one.
* Resource Limits (Ephemeral Storage):
You can control the amount of disk space a CN pod can consume by specifying ephemeral-storage requests and limits in the resources section of the `starRocksCnSpec`:
yaml
starRocksCnSpec:
resources:
requests:
ephemeral-storage: "20Gi"
limits:
ephemeral-storage: "50Gi"
This ensures the CN node has a guaranteed amount of local disk space and is prevented from consuming more than the specified limit on the host node, effectively "assigning" a disk size without a dedicated PVC.
Summary
* Default: Node-dependent (uses emptyDir).
* Adjustment: Use resources.limits.ephemeral-storage to set a cap without using a PVC.
References
• deployment/sr_operator.md
• quick_start/helm.md
• administration/management/FE_configuration.md