Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: file-backed cgd backup question
gdt%lexort.com@localhost (Greg Troxel) writes:
>> vnd opens the backing file when the unit is created and closes
>> the backing file when the unit is destroyed. Then you can access
>> the file again.
>Is there a guarantee of cache consistency for writes before and reads
>after?
Before the unit is created you can access the file and after the
unit is destroyed you can access the file. That's always safe.
I also think that when the unit is configured but not opened
(by device access or mounts) it is safe to access the file.
>> The data is written directly to the allocated blocks of the file.
>> So exclusively opening the backing file _or_ the vnd unit should
>> also be safe. But that's not much different from accessing any file
>> concurrently, which also leads to "corrupt", inconsistent backups.
>That's a different kind of corrupt.
Yes, but in the end it's the same, the "backup" isn't usuable.
You cannot access the backing file to get a consistent state of the
data while a unit is in use. And that's independent of how vnd accesses
the bits.
N.B. if you want to talk about dangers, think about fdiscard(). I
doubt that it is safe in the context of the vnd optimization.
Home |
Main Index |
Thread Index |
Old Index