ClickHouse Cloud Platform¶
ClickHouse Cloud is the managed cloud version of ClickHouse, providing serverless and dedicated compute options with automatic scaling. BenchBox provides first-class ClickHouse Cloud support, inheriting ClickHouse’s SQL dialect and benchmark compatibility.
Features¶
Managed ClickHouse - No infrastructure management
ClickHouse dialect - Inherits SQL dialect from ClickHouse
HTTPS connectivity - Secure connection via port 8443
Serverless & dedicated - Flexible compute options
Auto-scaling - Automatic resource management
Compression - Network-efficient data transfer
Quick Start¶
# Install clickhouse-connect
uv add clickhouse-connect
# Set your credentials
export CLICKHOUSE_CLOUD_HOST=abc123.us-east-2.aws.clickhouse.cloud
export CLICKHOUSE_CLOUD_PASSWORD=your-password
# Run benchmark
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0
Authentication¶
Getting Your Credentials¶
Sign in to clickhouse.cloud
Navigate to your service
Click “Connect” to get your connection details:
Host:
abc123.us-east-2.aws.clickhouse.cloudPort:
8443(HTTPS)Username: Usually
defaultPassword: Your service password
Configuration¶
Environment Variables (recommended):
export CLICKHOUSE_CLOUD_HOST=abc123.us-east-2.aws.clickhouse.cloud
export CLICKHOUSE_CLOUD_PASSWORD=your-password
export CLICKHOUSE_CLOUD_USER=default # optional, defaults to 'default'
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0
CLI Options:
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0 \
--platform-option host=abc123.us-east-2.aws.clickhouse.cloud \
--platform-option password=your-password \
--platform-option username=default
Configuration Options¶
Option |
Environment Variable |
Default |
Description |
|---|---|---|---|
|
|
- |
Cloud hostname (required) |
|
|
- |
Authentication password (required) |
|
|
|
Username |
|
- |
|
Target database |
|
- |
- |
Max memory per query (bytes) |
|
- |
- |
Query timeout (seconds) |
|
- |
|
Disable result cache for benchmarking |
|
- |
|
Enable network compression |
Usage Examples¶
Basic Benchmark¶
# TPC-H at scale factor 1
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0
# TPC-DS at scale factor 10
benchbox run --platform clickhouse-cloud --benchmark tpcds --scale 10.0
# ClickBench (ClickHouse's own benchmark)
benchbox run --platform clickhouse-cloud --benchmark clickbench
Custom Database Name¶
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0 \
--platform-option database=my_benchmarks
Performance Tuning¶
# Increase memory limit for complex queries
benchbox run --platform clickhouse-cloud --benchmark tpcds --scale 100 \
--platform-option max_memory_usage=16000000000
# Set query timeout
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 10 \
--platform-option max_execution_time=300
Dry Run (Preview)¶
# Preview what will be executed without running
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0 --dry-run ./preview
Comparison with Base ClickHouse¶
Feature |
ClickHouse (local) |
ClickHouse (server) |
ClickHouse Cloud |
|---|---|---|---|
CLI Name |
|
|
|
Infrastructure |
None (chDB) |
Self-hosted |
Managed |
Driver |
chdb |
clickhouse-driver |
clickhouse-connect |
Port |
N/A |
9000 (native) |
8443 (HTTPS) |
Authentication |
None |
Optional |
Required |
Best For |
Development |
Production self-hosted |
Production cloud |
Migration from Deployment Mode¶
If you were previously using --platform clickhouse:cloud, update your commands:
# Old syntax (deprecated but still works via alias)
benchbox run --platform clickhouse:cloud --benchmark tpch --scale 1.0
# New syntax (recommended)
benchbox run --platform clickhouse-cloud --benchmark tpch --scale 1.0
The clickhouse:cloud syntax is aliased to clickhouse-cloud for backward compatibility.
Troubleshooting¶
Connection Refused¶
Error: Cannot connect to ClickHouse Cloud
Solutions:
Verify your host URL is correct (should end with
.clickhouse.cloud)Check that your IP is allowed in the ClickHouse Cloud console
Ensure the service is running (not paused)
Authentication Failed¶
Error: Authentication failed for user 'default'
Solutions:
Verify your password is correct
Check if the user has the required permissions
Try resetting the password in the ClickHouse Cloud console
Missing Host Configuration¶
Error: ClickHouse Cloud requires host configuration.
Solutions:
Set
CLICKHOUSE_CLOUD_HOSTenvironment variableOr use
--platform-option host=your-host.clickhouse.cloud
Platform Information¶
At runtime, BenchBox captures platform metadata:
{
"platform_type": "clickhouse-cloud",
"platform_name": "ClickHouse Cloud",
"connection_mode": "cloud",
"configuration": {
"deployment": "managed",
"host": "abc123.us-east-2.aws.clickhouse.cloud",
"port": 8443,
"secure": True
}
}
See Also¶
ClickHouse Local Mode - Embedded ClickHouse via chDB
Deployment Modes Guide - Platform deployment architecture
Platform Comparison Matrix - Compare all platforms
TPC-H Benchmark - TPC-H benchmark guide