I'm trying to figure out whether I should go with local NVMe storage or networked cloud volumes for my CNPG (Cloud Native PostgreSQL) setup. I've heard local storage is preferred because it provides much better performance, but I'm a bit concerned about how to scale up in the future if I need more disk space. Currently, I'm considering using Hetzner's NVMe disks for local storage but am unsure about the possible scaling challenges later on. Conversely, I've read that while using Hetzner's cloud volumes can lead to a performance hit, they might be adequate for regular workloads. I'd love to know if anyone has faced issues with networked cloud storage for databases and whether I should strictly adhere to CNPG's recommendation of local storage!
2 Answers
Honestly, I'd avoid network volumes for any serious database project. They only offer around 7500 IOPS and a maximum of 300 MB/s for bursts, which typically averages out closer to 5000 IOPS. Local NVMe, on the other hand, can provide 55-60K IOPS. The performance difference can be massive depending on your use case.
It really comes down to your performance needs. We've been running some smaller databases for our web apps on Hetzner cloud volumes without any real issues, but if your app is performance-sensitive, you might want to think twice about using those cloud volumes.
That's exactly my worry! I don't want to risk having 'just enough' performance with those optimistic numbers. Is scaling local storage just a matter of switching to a larger disk, or is there a better approach I should consider?