[OpenAFS] Advice on using BTRFS for vicep partitions on Linux

Jeffrey E Altman jaltman@auristor.com
Wed, 22 Mar 2023 15:26:51 -0400


This is a cryptographically signed message in MIME format.

--------------ms010209080807090504030101
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit

On 3/22/2023 9:34 AM, Ciprian Craciun (ciprian.craciun@gmail.com) wrote:
> On Wed, Mar 22, 2023 at 10:30 AM <spacefrogg-openafs@spacefrogg.net> wrote:
>> OpenAFS implements its own CoW and using CoW below that again has no benefits and disturbs the fileservers "free-space" assumptions. It knows when it makes in-place updates and does not expect to run out of space in that situation.
> At what level does OpenAFS implement CoW?  Is it implemented at
> whole-file-level, i.e. changing a file that is part of a replicated /
> backup volume it will copy the entire file, or is it implemented at
> some range or smaller granularity level (i.e. it will change only that
> range, but share the rest)?
OpenAFS performs CoW on whole files within a Volume on the first update 
after a
Volume clone is created.  The clone can be a ROVOL, BACKVOL or untyped 
clone.

OpenAFS CoW is limited to sharing a vnode between multiple Volume instances.
Once a vnode can no longer be shared between two or more Volumes, the vnode
is copied.

OpenAFS does not perform CoW at a byte range level.

On Linux btrfs and xfs both support CoW at the block level.   A one byte 
change to
a 1GB file on btrfs will result in one block being copied and 
modified.   Whereas
OpenAFS will copy the entire 1GB.

>>> Unfortunately (at least for my use-case) losing the checksumming and
>>> compression is a no-go, because these were exactly the features that
>>> made BTRFS appealing versus Ext4.
>> If you say so...
>> AFS does its own data checksumming.
>>
OpenAFS does not maintain checksums.  Checksums are neither transmitted in
the RXAFS_FetchData and RXAFS_StoreData RPCs messages nor are checksums
stored and compared when reading and writing to the vice partition.
> Granted, RAID is not a backup solution, but it should instead protect
> one from faulty hardware.  Which is exactly what it doesn't do 100%,
> because if one of the drive in the array returns corrupted data, the
> RAID system can't say which one is it (based purely on the returned
> data).  Granted, disks don't just return random data without any other
> failure or symptom.
Bit flips occur more frequently than we would like which was the 
rationale behind
adding checksums and multiple copies and self-healing to ZFS.
> With regard to file-system scrubbing, to my knowledge, only those that
> actually have checksumming can do this, which currently is either
> BTRFS or ZFS.
There are some other examples but these are the only two regularly 
available as
a local Linux filesystem.

Jeffrey Altman



--------------ms010209080807090504030101
Content-Type: application/pkcs7-signature; name="smime.p7s"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="smime.p7s"
Content-Description: S/MIME Cryptographic Signature

MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgEFADCABgkqhkiG9w0BBwEAAKCC
DHEwggXSMIIEuqADAgECAhBAAYJpmi/rPn/F0fJyDlzMMA0GCSqGSIb3DQEBCwUAMDoxCzAJ
BgNVBAYTAlVTMRIwEAYDVQQKEwlJZGVuVHJ1c3QxFzAVBgNVBAMTDlRydXN0SUQgQ0EgQTEz
MB4XDTIyMDgwNDE2MDQ0OFoXDTI1MTAzMTE2MDM0OFowcDEvMC0GCgmSJomT8ixkAQETH0Ew
MTQxMEQwMDAwMDE4MjY5OUEyRkQyMDAwMjMzQ0QxGTAXBgNVBAMTEEplZmZyZXkgRSBBbHRt
YW4xFTATBgNVBAoTDEF1cmlTdG9yIEluYzELMAkGA1UEBhMCVVMwggEiMA0GCSqGSIb3DQEB
AQUAA4IBDwAwggEKAoIBAQCkC7PKBBZnQqDKPtZPMLAy77zo2DPvwtGnd1hNjPvbXrpGxUb3
xHZRtv179LHKAOcsY2jIctzieMxf82OMyhpBziMPsFAG/ukihBMFj3/xEeZVso3K27pSAyyN
fO/wJ0rX7G+ges22Dd7goZul8rPaTJBIxbZDuaykJMGpNq4PQ8VPcnYZx+6b+nJwJJoJ46kI
EEfNh3UKvB/vM0qtxS690iAdgmQIhTl+qfXq4IxWB6b+3NeQxgR6KLU4P7v88/tvJTpxIKkg
9xj89ruzeThyRFd2DSe3vfdnq9+g4qJSHRXyTft6W3Lkp7UWTM4kMqOcc4VSRdufVKBQNXjG
IcnhAgMBAAGjggKcMIICmDAOBgNVHQ8BAf8EBAMCBPAwgYQGCCsGAQUFBwEBBHgwdjAwB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