[mythtv-users] warning for anyone with western digital green drives

Mark Lord mythtv at rtr.ca
Fri Jan 6 13:57:31 UTC 2012


On 12-01-06 06:15 AM, Simon Hobson wrote:
..
> On writes it might not help if the OS issues a write and then waits 
> for the drive to confirm that the data has been written - that 
> question needs input from someone who knows how Linux (and in this 
> context, Myth) operate. When data is written to the drives, does the 
> OS just wait for the drive to acknowledge the transfer (into buffer), 
> or for the drive to confirm that it's been written.

Normally Linux applications, including mythtv, will invoke fsync()
and or fdatasync() to wait for data to be flushed to the actual disk.
The Linux kernel responds to those requests by issuing flush-cache
commands to the drive, and waits for confirmation of completion.

Yes, this slows down the system quite a bit, which is why there
are also numerous threads here about using "barrier=0" when mounting
filesystems, to disable the synchronous cache-flushes.

Doing that is reasonably safe, even with power-failures.
Though to be completely paranoidically safe about it
the drives should be powered from an uninterruptible power supply (UPS).

Cheers


More information about the mythtv-users mailing list