Deploying to Amazon Web Services (AWS)
Hardware recommendations
CPU/RAM
A production instance for QuestDB should be provisioned with at least 4 vCPUs
and 8 GiB
of memory. If possible,
a 1:4 vCPU/RAM
ratio should be used. Some use cases may benefit from a 1:8
ratio, if this means that all the working
set data will fit into memory; this can increase query performance by as much as 10x
.
It is not recommended to run production workloads on less than 4 vCPUs
, as below this number, parallel querying optimisations
may be disabled. This is to ensure there is sufficient resources available for ingestion.
Architecture
QuestDB should be deployed on Intel/AMD architectures i.e. x86_64
and not on ARM
i.e. aarch64
. Some optimisations are not available
on ARM
, e.g. SIMD
.
Storage
Data should be stored on a data disk with at minimum 3000 IOPS/125 MBps, and ideally at least 5000 IOPS/300 MBps. Higher end workloads should scale up the disks appropriately, or use multiple disks if necessary.
It is also worth checking the burst capacity of your storage. This capacity should only be used during heavy I/O spikes/infrequent out-of-order (O3) writes. It is useful to have in case you hit unexpected load bursts.
Elastic Compute Cloud (EC2) with Elastic Block Storage (EBS)
We recommend starting with M6
instances, with an upgrade to
R6
instances if extra RAM is needed. You can use either i
(Intel) or a
(AMD) instsance.
These should be deployed with an x86_64
Linux distribution, such as Ubuntu.
For storage, we recommend using gp3
disks, as these provide a better price-to-performance
ratio compared to gp2
or io1
offerings.5000 IOPS/300 MBps
is a good starting point until
you have tested your workload.
For the file system, use zfs
with lz4
, as this will compress your data. If compression
is not a concern, then use ext4
or xfs
for a little higher performance.
Elastic File System (EFS)
QuestDB does not support EFS
for its primary storage. Do not use it instead of EBS
.
You may be able to use it as an object store, but we would recommend using S3
instead, as a simpler,
and cheaper, alternative.
Simple Storage Service (S3)
QuestDB supports S3
as its replication object-store in the Enterprise edition.
This requires very little provisioning - simply create a bucket or virtual subdirectory and follow the Enterprise Quick Start steps to configure replication.
Minimum specification
- Instance:
m6i.xlarge
orm6a.xlarge
(4 vCPUs, 16 GiB RAM)
- Storage
- OS disk:
gp3 (30 GiB)
volume provisioned with3000 IOPS/125 MBps
. - Data disk:
gp3 (100 GiB)
volume provisioned with3000 IOPS/125 MBps
.
- OS disk:
- Operating System:
Linux Ubuntu 24.04 LTS x86_64
. - File System:
ext4
Better specification
- Instance:
r6i.2xlarge
orr6a.2xlarge
(8 vCPUs, 64 GiB RAM)
- Storage
- OS disk:
gp3 (30 GiB)
volume provisioned with5000 IOPS/300 MBps
. - Data disk:
gp3 (300 GiB)
volume provisioned with5000 IOPS/300 MBps
.
- OS disk:
- Operating System:
Linux Ubuntu 24.04 LTS x86_64
. - File System:
zfs
withlz4
compression.
Launching QuestDB on EC2
Once you have provisioned your EC2
instance with attached EBS
storage, you can simply
follow the setup instructions for a Docker or systemd installation.
You can also keep it simple - just download the binary and run it directly. QuestDB is a single self-contained binary and easy to deploy.
Launching QuestDB on the AWS Marketplace
AWS Marketplace is a digital catalog with software listings from independent software vendors that runs on AWS. This guide describes how to launch QuestDB via the AWS Marketplace using the official listing. This document also describes usage instructions after you have launched the instance, including hints for authentication, the available interfaces, and tips for accessing the REST API and Web Console.
The QuestDB listing can be found in the AWS Marketplace under the databases category. To launch a QuestDB instance:
- Navigate to the QuestDB listing
- Click Continue to Subscribe and subscribe to the offering
- Configure a version, an AWS region and click Continue to Launch
- Choose an instance type and network configuration and click Launch
An information panel displays the ID of the QuestDB instance with launch configuration details and hints for locating the instance in the EC2 console.
The default user is admin
and password is quest
to log in to the webconsole.
QuestDB configuration
Connect to the instance where QuestDB is deployed using SSH. The server configuration file is at the following location on the AMI:
/var/lib/questdb/conf/server.conf
For details on the server properties and using this file, see the server configuration documentation.
The default ports used by QuestDB interfaces are as follows:
- Web Console & REST API is available on port
9000
- PostgreSQL wire protocol available on
8812
- InfluxDB line protocol
9009
(TCP and UDP) - Health monitoring & Prometheus
/metrics
9003
Postgres credentials
Generated credentials can be found in the server configuration file:
/var/lib/questdb/conf/server.conf
The default Postgres username is admin
and a password is randomly generated
during startup:
pg.user=admin
pg.password=...
To use the credentials that are randomly generated and stored in the
server.conf
file, restart the database using the command
sudo systemctl restart questdb
.
InfluxDB line protocol credentials
The credentials for InfluxDB line protocol can be found at
/var/lib/questdb/conf/full_auth.json
For details on authentication using this protocol, see the InfluxDB line protocol authentication guide.
Disabling authentication
If you would like to disable authentication for Postgres wire protocol or InfluxDB line protocol, comment out the following lines in the server configuration file:
# pg.password=...
# line.tcp.auth.db.path=conf/auth.txt
Disabling interfaces
Interfaces may be disabled completely with the following configuration:
# disable postgres
pg.enabled=false
# disable InfluxDB line protocol over TCP and UDP
line.tcp.enabled=false
line.udp.enabled=false
# disable HTTP (web console and REST API)
http.enabled=false
The HTTP interface may alternatively be set to readonly:
# set HTTP interface to readonly
http.security.readonly=true
Upgrading QuestDB
- Check the release notes and ensure that necessary backup is completed.
You can perform the following steps to upgrade your QuestDB version on an official AWS QuestDB AMI:
- Stop the service:
systemctl stop questdb.service
- Download and copy over the new binary
wget https://github.com/questdb/questdb/releases/download/8.2.2/questdb-8.2.2-no-jre-bin.tar.gz \
tar xzvf questdb-8.2.2-no-jre-bin.tar.gz
cp questdb-8.2.2-no-jre-bin/questdb.jar /usr/local/bin/questdb.jar
cp questdb-8.2.2-no-jre-bin/questdb.jar /usr/local/bin/questdb-8.2.2.jar
- Restart the service again:
systemctl restart questdb.service
systemctl status questdb.service