GregM
05/14/2026, 6:26 PMRocky
05/14/2026, 6:26 PMDISTRIBUTED BY clause, StarRocks defaults to Random Bucketing. Starting from version 3.2, StarRocks automatically includes the "bucket_size" = "1073741824" property (which is exactly 1 GB in bytes) to enable Automatic/Dynamic Bucketing.
Why this happens:
* Default Distribution: If no bucketing is specified for a Duplicate Key table, StarRocks uses Random Bucketing by default.
* Dynamic Scaling: The bucket_size property allows StarRocks to dynamically increase the number of buckets (split tablets) in a partition as more data is loaded.
* Default Value: The system-wide default for this feature is 1 GB (1,073,741,824 bytes). By setting this, StarRocks ensures that individual tablets stay at a healthy size for performance and maintenance.
Key points to note:
* Appears in DDL: Because this is now the default configuration for Duplicate Key tables with random distribution, it will show up in the SHOW CREATE TABLE output even if you didn't explicitly type it.
* When it's used: This only applies to Duplicate Key tables. Other table types (like Primary Key or Unique Key) still require you to define a hash bucketing key.
* Rollback Warning: If you ever need to rollback to a version earlier than 3.2 (where this property isn't recognized), you may need to delete tables using this feature first, as it introduces metadata changes.
If you prefer a different size or want to disable it (by setting a fixed number of buckets), you can specify DISTRIBUTED BY RANDOM BUCKETS <num> during table creation instead.
References
• table_design/data_distribution/Data_distribution.md
• sql-reference/sql-statements/table_bucket_part_index/CREATE_TABLE.mdGregM
05/14/2026, 6:28 PMRocky
05/14/2026, 6:28 PMbucket_size to 4294967296 (4 GB) helps prevent the "Too Many Tablets" problem, which can degrade cluster stability.
* Decrease (Rare): If you have very small nodes (low CPU/RAM) and very small data volumes, but generally, 1 GB is safe even then, as StarRocks won't create extra buckets unless the data actually grows to fill them.
Summary
For most users, leaving it at 1 GB is the best "set it and forget it" approach. It allows the system to scale the number of buckets automatically as your data grows without requiring you to manually calculate bucket counts for every table.
References
• table_design/data_distribution/Data_distribution.md
• best_practices/bucketing.md
References
• best_practices/bucketing.md
• knowledge/usage/best-practice.md
• table_design/data_distribution/Data_distribution.md
• administration/management/FE_configuration.md