Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

What's the point of using sync commits if you don't actually ensure that the data is on two machines before the transaction is committed?


I think OP wants at least one machine that is healthy and fully operational at any point in time. But the cost of a three machine setup is too great. There are three main failures scenarios.

1. Primary fails and standby takes over. Sync mode helps here because there should be no data loss for completed transactions. In async mode, there could be some data loss for completed transactions.

2. Standby fails and primary continues to operate normally. When the standby is back online, it catches up. Currently the primary would not be able to continue to operate normally because of those config settings.

3. Both primary and standby fail simultaneously. A very unlikely scenario but can be solved with WAL archiving which does have the risk of potential data loss.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: