Is it possible to shrink a volume? I have one that is much to large for my needs (was created by fly pg automatically) and not sure my best approach to get it down a bit.
Seeing that persistent storage is billed per GB, I’m assuming the lowest you can go is
1G, when creating with
fly pg create and answering with
1G in the volume size prompt.
It defaults to
10G, as seen in the source code.
I found an old comment (Dec '20) that says resizing wasn’t possible then.
- snapshot of your current pg
- pg create with
1G, restoring from snapshot (Multi-region PostgreSQL)
Requires a bit of trial and error, if that’s doable.
Is this a volume for a replica? You can create a smaller volume, then add a Postgres VM and let it replicate.
There’s no current way to shrink a volume. We have a lot of storage features that are basically “second most important” on the infrastructure roadmap (meaning, work we’ll start after the next round of hiring). Resizing volumes is one of them.