Dan Browning wrote:
>
> How do I force Linux (2.2.5, on rh6) to flush the hard drive cache?
sync
> Seperately, how do I disable the cache and force all writes to be immediate?
>
You can't. But you can mount ext2 filesystems with the sync option.
> I am wondering because of scenarios when a power outage might be
> emminent-but I cannot shut down the box.
SuSE shutdown scripts do an extra 'sync' when umounting fails.
> Hopefully flushing and disabling
> the cache would reduce data-loss after the outage.
>
> What other steps should be taken to ensure data safety during such a
> scenario? Thanks for the help,
Buy an UPS. They are cheap nowadays. Then add the sync calls to your
shutdown script.
Marc
--
Marc Mutz <[EMAIL PROTECTED]> http://marc.mutz.com/
University of Bielefeld, Dep. of Mathematics / Dep. of Physics
PGP-keyID's: 0xd46ce9ab (RSA), 0x7ae55b9e (DSS/DH)