Remediation Hub (9)
Configure PostgreSQL LC_COLLATE=C and Shared Buffers for Synapse
Synapse refuses to boot on non-C collation databases because locale-aware text sorting breaks Matrix ID index lookups.
Required Init: --lc-collate=C --lc-ctype=C | Target: UTF8
Step 1: Create the Synapse Database with C Collation
When initializing PostgreSQL for Synapse, execute CREATE DATABASE synapse ENCODING 'UTF8' LC_COLLATE='C' LC_CTYPE='C' TEMPLATE=template0 OWNER synapse;. Standard en_US.UTF-8 collation causes glibc upgrades to corrupt B-tree indexes.
Step 2: Size shared_buffers and work_mem for 4-8 GB VPS Nodes
Set shared_buffers to 25% of VPS RAM (e.g., 1 GB on a 4 GB Vultr HF node, 2 GB on an 8 GB node), effective_cache_size to 60%, and random_page_cost = 1.1 for NVMe storage.
Measured Thresholds & Configuration
| Postgres Parameter | 4 GB VPS (Vultr HF) | 8 GB VPS (Vultr HF / KVM 2) |
|---|---|---|
| LC_COLLATE / LC_CTYPE | C / C (mandatory) | C / C (mandatory) |
| shared_buffers | 1024 MB | 2048 MB |
| random_page_cost | 1.1 (NVMe SSD) | 1.1 (NVMe SSD) |