Scaling
How to scale your Zektor.io database instances — vertical scaling, cluster resizing, and performance optimization.
Overview
Zektor.io supports vertical scaling — upgrading or changing the compute resources (CPU, RAM, storage) allocated to your database instance. You can scale your instance at any time from the dashboard.
Cluster Sizes
Each database engine offers multiple cluster sizes (tiers). Choose the right tier based on your workload:
PostgreSQL Tiers
| Tier | RAM | SSD Storage | max_connections | Price |
|---|---|---|---|---|
| Starter | 512MB | 5GB | 25 | €5.00/mo |
| Standard | 1GB | 10GB | 50 | €10.00/mo |
| Pro | 2GB | 20GB | 100 | €20.00/mo |
| Business | 4GB | 40GB | 200 | €40.00/mo |
Valkey Tiers
| Tier | RAM | Price |
|---|---|---|
| Starter | 128MB | €2.00/mo |
| Standard | 256MB | €4.00/mo |
| Pro | 512MB | €8.00/mo |
| Business | 1GB | €15.00/mo |
How to Scale
Scaling Up (Upgrading)
- Navigate to your instance's Settings tab
- Under Cluster Size, select a larger tier
- Click Save Changes
- The resize process will begin automatically
Scaling Down (Downgrading)
You can also scale down to a smaller tier to reduce costs:
- Ensure your data fits within the smaller tier's storage limit
- Navigate to your instance's Settings tab
- Select a smaller tier
- Click Save Changes
Note: Scaling down is only possible if your current data usage fits within the target tier's resources. If your database is using 8GB of storage, you cannot scale down to the Starter tier (5GB).
What Happens During a Resize
When you resize a PostgreSQL instance:
- A new instance with the target cluster size is provisioned
- Your data is migrated to the new instance
- Connection endpoints are updated to point to the new instance
- The old instance is decommissioned
Downtime: There is a brief period of downtime during the cutover, typically a few seconds. The exact duration depends on your database size.
Connections: Existing connections will be terminated during the cutover. Applications with connection pooling and retry logic will reconnect automatically.
In-flight queries: Any queries running during the cutover will fail. Ensure your application handles transient errors gracefully.
Billing: Tier changes are prorated to the day. You only pay for each tier for the days you used it.
Resizing Branches
Each branch can be independently sized. You don't need to match the cluster size of your main branch — this is useful for running cheaper development branches.
Storage Auto-Scaling
PostgreSQL instances with persistent storage support automatic disk scaling:
- Scale up: When disk usage exceeds 80%, storage is automatically increased by 5GB
- Scale down: When disk usage drops below 60%, storage can be reduced (deferred to off-peak hours to avoid oscillation)
- Limits: Auto-scaling respects the maximum storage limit for your tier
Additional storage beyond your tier's included amount is billed at €0.09/GB per month.
You can monitor your current storage usage in the Monitoring dashboard.
When to Scale
Signs You Need to Scale Up
| Symptom | Likely Cause | Solution |
|---|---|---|
| High CPU usage (>80% sustained) | Heavy query load | Upgrade to a larger cluster |
| High memory usage (>90%) | Large working set | More RAM for buffer cache |
| Disk usage approaching limit | Data growth | Larger tier with more storage |
FATAL: too many clients | Connection limit reached | Upgrade tier or use pooling |
| Slow query performance | Insufficient resources | More CPU/RAM |
Choosing the Right Tier
- Starter — Small projects, prototypes, development databases
- Standard — Production applications with moderate traffic
- Pro — Growing applications with significant query load
- Business — High-traffic production workloads
- Custom — Contact us for dedicated resources
Performance Optimization
Before scaling up, consider these optimizations that often solve performance issues for free:
PostgreSQL
-
Add indexes — Missing indexes are the #1 cause of slow queries
-- Find tables with mostly sequential scans SELECT relname, seq_scan, idx_scan FROM pg_stat_user_tables WHERE seq_scan > idx_scan ORDER BY seq_scan DESC; -
Use connection pooling — Reduce connection overhead with PgBouncer or application-level pooling
-
Optimize queries — Use
EXPLAIN ANALYZEto identify slow operationsEXPLAIN ANALYZE SELECT * FROM orders WHERE customer_id = 42; -
VACUUM regularly — PostgreSQL needs VACUUM to reclaim space and update statistics
VACUUM ANALYZE; -
Check for table bloat — Large, frequently-updated tables can accumulate dead tuples
Valkey
- Use appropriate data structures — Choose Sets, Sorted Sets, Hashes over individual keys
- Set TTLs on keys — Prevent unbounded memory growth
- Use pipelining — Batch commands to reduce round trips
- Monitor eviction — If keys are being evicted, you need more memory
Need Larger Instances?
For deployments requiring more than our standard tier offerings — or for dedicated hardware, custom networking, or compliance requirements — contact us.
Next Steps
- Monitoring — Track resource usage and identify bottlenecks
- Connecting — Configure connection pooling
- Pricing — Understand costs for each tier
- Limits & Quotas — Storage and connection limits per tier