Simon Paradis
04/14/2026, 6:09 PMlogStorageSize: 0Gi ?Rocky
04/14/2026, 6:10 PMlogStorageSize: 0Gi is technically "safe" in that the cluster will still function, but it is not recommended for production environments due to the loss of log persistence.
Here is a detailed breakdown of what happens and the associated risks:
1. What happens when you set 0Gi?
When logStorageSize is set to 0Gi in your StarRocksCluster CRD or Helm chart:
* No PVC Created: The StarRocks Operator will not create a Persistent Volume Claim (PVC) for log storage.
* Ephemeral Storage (emptyDir): Instead of using a persistent disk, the logs will be stored in an emptyDir volume (specifically at /opt/starrocks/{fe|be|cn}/log).
* Logs are Ephemeral: Because emptyDir is tied to the Pod's lifecycle, all logs stored there are permanently deleted whenever the Pod restarts, crashes, or is rescheduled.
2. Is it safe?
* Functionally Safe: Yes. The FE/BE/CN processes will still start and write logs to the local container directory. There is no hard requirement for a dedicated PVC for the cluster to "work."
* Operationally Unsafe: No. Troubleshooting becomes significantly harder. If a node crashes (which is exactly when you need logs the most), the logs explaining the crash will disappear the moment the Pod restarts.
3. Recommendations
If you are considering setting it to 0Gi to save on storage costs or complexity:
* For Production: Always provide a minimum logStorageSize (e.g., 10Gi or 20Gi) to ensure you can investigate historical issues and crashes.
* Log to Console: If you choose not to use PVCs, ensure you have enabled console logging (e.g., setting LOG_CONSOLE=1 in the environment variables) and are using a log aggregation tool like Vector, Fluentd, or Datadog to ship logs to a central location.
* Check Meta Storage: Be careful not to confuse logStorageSize with storageSize. For FE nodes, storageSize is used for *metadata*; setting that to 0Gi or having it run out of space will cause the FE to stop running and can lead to data loss.
Summary: Only use logStorageSize: 0Gi for short-lived test clusters or development environments where log history is not a concern. For any serious deployment, use persistent storage for logs.
References
• administration/management/BE_configuration.md
• administration/management/FE_configuration.md
• administration/management/logs.md