Piotr Gasidło wrote:
> I _can_ afford of loosing some data in case of power failure. But I'm
> afraid of having database in unrecoverable state after crash.
>
Then turn off synchronous_commit. That's exactly the behavior you get
when it's disabled: some data loss after a crash, no risk of database
corruption, and faster performance without needing a controller with a
battery.
If you've already got a RAID controller that accepts a battery, it would
be silly not to then buy one though. The controller is normally 75% of
the price of the combination, so getting that but not the final piece to
really make it perform well wouldn't be a good move.
--
Greg Smith 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD
PostgreSQL Training, Services, and 24x7 Support www.2ndQuadrant.us
"PostgreSQL 9.0 High Performance": http://www.2ndQuadrant.com/books