Is it preferable to use the sync command?
rihad
rihad at mail.ru
Wed Jun 24 09:48:40 UTC 2009
Simun Mikecin wrote:
> rihad wrote:
>> Having experienced a FreeBSD 5.1 crash due to power failure (despite using a UPS) resulting in massive /etc corruption and data loss, in order to minimize future risks should I:
>> 0) tweak (decrease) these default sysctls:
>> kern.filedelay: 30
>> kern.dirdelay: 29
>> kern.metadelay: 28
>> 1) mount the root FS with soft-updates enabled (left as disabled in sysinstall by default due to known reasons)
>> 2) setup a cron job calling /bin/sync every minute
>> I somehow feel that turning soft-updates on would do the trick (it is not normally written to and has plenty of free space anyway).
>
>
> Do you use ATA or SCSI?
ATA.
> Turning soft-updates on for SCSI should do the trick.
But not for ATA? Why I'm asking: other partitions using soft-updates
don't seem to have lost any data.
> Since there is no support for gjournal and/or ZFS on 5.1, for ATA only real solution would be disabling write-cache (which degrades performance): "sysctl hw.ata.wc=0".
>
I think this is much easier to do remotely than turning soft-updates on
:-) I'll still try both solutions, thanks.
More information about the freebsd-fs
mailing list