Actions
Enhancement #75705
closed
MS
IF
Add mask parameter to ceph_open_snapdiff() to include file attribute changes in snapdiff
Enhancement #75705:
Add mask parameter to ceph_open_snapdiff() to include file attribute changes in snapdiff
Status:
Backporting
Priority:
Normal
Assignee:
Category:
Correctness/Safety
Target version:
Due date:
% Done:
0%
Source:
Development
Backport:
tentacle,squid,umbrella
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
MDS
Labels (FS):
Pull request ID:
Tags (freeform):
Merge Commit:
Fixed In:
v21.3.0-1755-g0cf2acd653
Released In:
Upkeep Timestamp:
2026-08-27T18:44:13+00:00
Description
The ceph_open_snapdiff() API currently opens a snapdiff stream for retrieving differences between two snapshots. However, snapdiff today primarily focuses on entry-level changes and does not provide a way to account for file attribute modifications.
This becomes a limitation when a file remains present across both snapshots but some of its metadata changes, such as mode, ownership, timestamps, or other relevant attributes. In such cases, the file may not appear in the snapshot diff even though its state has changed.
To address this, ceph_open_snapdiff() should be extended with an additional mask parameter. This parameter would specify which attribute changes should be considered while computing snapshot differences.
Proposed API changes:¶
int ceph_open_snapdiff(struct ceph_mount_info* cmount,
const char* root_path,
const char* rel_path,
const char* snap1,
const char* snap2,
unsigned int mask,
struct ceph_snapdiff_info* out);
Expected behavior:¶
- The new mask parameter controls which file attribute changes are included in snapdiff.
- If relevant attributes differ between snap1 and snap2, the file should be reported in the snapshot diff even when there is no create, delete, or rename event.
- This allows callers to customize diff behavior depending on which metadata changes matter for their use case.
IF Updated by Igor Fedotov 8 months ago
- Status changed from New to Fix Under Review
- Backport changed from tentacle,squid,reef to tentacle,squid
- Pull request ID set to 68054
IF Updated by Igor Fedotov 5 months ago
- Related to Bug #77892: mds/snap_diff: snapdiff doesn't report a file has changed when the file is modified and mtime is preserved between two snapshots added
VS Updated by Venky Shankar 5 months ago
- Backport changed from tentacle,squid to tentacle,squid,umbrella
- Component(FS) MDS added
VS Updated by Venky Shankar 4 months ago
- Target version changed from v21.0.0 to v22.0.0
UB Updated by Upkeep Bot 4 months ago
- Status changed from Fix Under Review to Pending Backport
- Merge Commit set to 0cf2acd6539617ace3cbd99d5d83dcc0d60b19ff
- Fixed In set to v21.3.0-1755-g0cf2acd653
- Upkeep Timestamp set to 2026-08-05T05:49:37+00:00
UB Updated by Upkeep Bot 4 months ago
- Copied to Backport #79062: tentacle: Add mask parameter to ceph_open_snapdiff() to include file attribute changes in snapdiff added
UB Updated by Upkeep Bot 4 months ago
- Copied to Backport #79063: umbrella: Add mask parameter to ceph_open_snapdiff() to include file attribute changes in snapdiff added
UB Updated by Upkeep Bot 4 months ago
- Copied to Backport #79064: squid: Add mask parameter to ceph_open_snapdiff() to include file attribute changes in snapdiff added
UB Updated by Upkeep Bot 4 months ago
- Tags (freeform) set to backport_processed
VS Updated by Venky Shankar 4 months ago
- Related to Bug #79154: libcephfs: fix ABI breakage due to diff_mask snapdiff parameter added
UB Updated by Upkeep Bot 3 months ago
- Status changed from Pending Backport to Backporting
- Tags (freeform) deleted (
backport_processed) - Upkeep Timestamp changed from 2026-08-05T05:49:37+00:00 to 2026-08-27T18:44:13+00:00
Actions