Derek Coleman & Associates Inc logoDerek Coleman & Associates Inc

Home / Docs / ClickHouse (Hardened) / Install

Install ClickHouse (Hardened)

Launch, connect, and validate — with the expected result after every step.

Prerequisites

AWS

  1. Subscribe and launch (memory-optimized instances shine; 4 vCPU floor).
    Expected result clickhouse-client -q 'SELECT version()' returns.
  2. For network use: add a users.d/ user with a password, set listen_host in config.d, restart, and open 8123/9000 to your subnet only.
    Expected result Remote clickhouse-client authenticates; the default user remains local-only.

Google Cloud

  1. Deploy from the listing (IAP-only SSH; 8123/9000 closed by the package by default).
    Expected result On the VM: clickhouse-client -q 'SELECT version()' returns.
  2. For in-VPC clients: add a users.d/ user with a password, set listen_host in config.d/, `sudo systemctl restart clickhouse-server`, then add firewall rules for 8123/9000 from your subnet only.
    Expected result Remote clickhouse-client authenticates; the default user remains local-only.

Validate

clickhouse-client -q 'SELECT 1'

First boot: Service enabled at build (the build already proved SELECT 1 answers); ready in seconds. No credential is generated — the default user is passwordless and loopback-only.

First login / credentials

  1. SSH in with the key pair you chose at launch (AWS: ssh ec2-user@<public-ip>; GCP: gcloud compute ssh <vm> --tunnel-through-iap).
  2. Run `clickhouse-client` — the default user has no password and can only connect from the instance itself.
  3. Before exposing 8123/9000: create a user with a password in /etc/clickhouse-server/users.d/ (or `CREATE USER ... IDENTIFIED BY ...`), set listen_host in /etc/clickhouse-server/config.d/, restart, then open the firewall to your subnet only.

Secure it

Costs & quotas

Software is billed by the marketplace at the listed rate; infrastructure (VM, storage, egress) is billed by your cloud at its standard rates. The recommended size fits default service quotas in most accounts — if you scale out, review your cloud's quota console before launch.

Next: configuration · troubleshooting · security notes