apache/cassandra · info

Small volume detected at ' '; setting to . You can override…

Error message

Small {} volume detected at '{}'; setting {} to {}.  You can override this in cassandra.yaml

What it means

A startup warning from DatabaseDescriptor when auto-computed size settings (e.g. commitlog segment or disk-access-related sizes derived as a fraction of a volume) would exceed the actual space on a small volume. Cassandra clamps the setting to the calculated minimum (minSizeInMiB) and logs this so the operator knows to override it in cassandra.yaml.

Solutions

  1. Accept the warning — Cassandra already clamped the value; it is informational.
  2. If the clamped value is unsuitable, set the setting explicitly in cassandra.yaml (e.g. a fixed max_mutation_size/commitlog segment size appropriate to your volume).
  3. Give the data/commitlog directory a larger volume if the clamped value harms throughput.
  4. Suppress noise in test environments by provisioning adequate disk or pinning explicit config values.

Example fix

// before (cassandra.yaml)
# setting left to auto-sizing
// after
commitlog_segment_size_in_mb: 16  # explicit value for small volume
Defensive patterns

Strategy: validation

Validate before calling

# estimate auto-sized value before start
total_mib = shutil.disk_usage('/var/lib/cassandra').total // (1024*1024)
setting_mib = int(total_mib * numerator / denominator)
if setting_mib < preferred: print('will be clamped to', setting_mib)

Prevention

When it happens

Trigger: Starting a node on a small disk/volume (e.g. container or CI image with a few GiB) where totalSpaceNumerator/Denominator-based fraction of total volume size is smaller than the preferred default size in MiB for the given setting/path.

Common situations: Running Cassandra in Docker/Kubernetes with small ephemeral volumes; laptops/dev VMs; CI test runners; embedded/edge deployments where default sizes tuned for server disks don't fit.

Understand the failure class

Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.

Related errors


AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10). Data as JSON: /api/errors/dbb94ca91e76ca3a. Report an issue: GitHub.

Appendix: source

Thrown at src/java/org/apache/cassandra/config/DatabaseDescriptor.java:1482

        return storagedir(type + "_directory") + File.pathSeparator() + type;
    }

    private static String storagedir(String errMsgType)
    {
        String storagedir = STORAGE_DIR.getString();
        if (storagedir == null)
            throw new ConfigurationException(errMsgType + " is missing and " + STORAGE_DIR.getKey() + " system property is not set", false);
        return storagedir;
    }

    static int calculateDefaultSpaceInMiB(String type, String path, String setting, int preferredSizeInMiB, long totalSpaceInBytes, long totalSpaceNumerator, long totalSpaceDenominator)
    {
        final long totalSizeInMiB = totalSpaceInBytes / ONE_MIB;
        final int minSizeInMiB = Ints.saturatedCast(totalSpaceNumerator * totalSizeInMiB / totalSpaceDenominator);

        if (minSizeInMiB < preferredSizeInMiB)
        {
            logger.warn("Small {} volume detected at '{}'; setting {} to {}.  You can override this in cassandra.yaml",
                        type, path, setting, minSizeInMiB);
            return minSizeInMiB;
        }
        else
        {
            return preferredSizeInMiB;
        }
    }

    public static void applyAddressConfig() throws ConfigurationException
    {
        applyAddressConfig(conf);
    }

    public static void applyAddressConfig(Config config) throws ConfigurationException
    {
        listenAddress = null;
        rpcAddress = null;

View on GitHub (pinned to 88fd0f6a0e)