4 ms·
Sounds neat. What’s the weak link here though?
by ed25519FUUU 4y ago
Sounds neat. What’s the weak link here though?
- szundi 4y agoMaybe that zfs snaphot under a running database? Is that ok?
- alduin32 4y agoYes, ZFS snapshots are atomic, so as long as the database use sane semantics to do disk I/O, you're fine (AFAIK, PostgreSQL and MySQL/InnoDB are ok, MySQL/MyISAM is not though). A snapshot is effectively identical to a killed database server (due to OOM, or power outage), and database servers should be crash-resistant. With PostgreSQL, checkpointing the database before taking the snapshot may make the crash recovery quicker when loading the snapshotted database.
- skrtskrt 4y agoNo read replicas that can be promoted to master in an outage?
- alduin32 4y agoI have a similar setup as OP, and I use ZFS snapshots to be able to quickly rebuild the whole machine on another host. Of course, it still requires manual intervention in an outage (it could be automated, theoretically), and I may lose up to 5 minutes of data due to my snapshot schedule.
- davidzweig 4y agoAh, nop. If it goes down, we'll figure it out.. 24hrs outage wouldn't be the end of the world. Would have been nice to have a second (read replica) machine in East Asia, to reduce latency for users there, but didn't find a provider like Hetzner.. maybe could take a server in a suitcase and install it in a collocation center there. Bit of a hassle though.