Skip to content

mds: update older versioned sr_t struct(s) to incorporate snapshot visibility flag#65960

Merged
vshankar merged 2 commits intoceph:mainfrom
dparmar18:i73550
Dec 5, 2025
Merged

mds: update older versioned sr_t struct(s) to incorporate snapshot visibility flag#65960
vshankar merged 2 commits intoceph:mainfrom
dparmar18:i73550

Conversation

@dparmar18
Copy link
Contributor

@dparmar18 dparmar18 commented Oct 15, 2025

Fixes: https://tracker.ceph.com/issues/73550

Contribution Guidelines

  • To sign and title your commits, please refer to Submitting Patches to Ceph.

  • If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.

  • When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an x between the brackets: [x]. Spaces and capitalization matter when checking off items this way.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

@github-actions github-actions bot added the cephfs Ceph File System label Oct 15, 2025
@dparmar18 dparmar18 requested a review from a team October 15, 2025 11:51
@dparmar18
Copy link
Contributor Author

@vshankar should i also add an upgrade test case?

@vshankar
Copy link
Contributor

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@dparmar18
Copy link
Contributor Author

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

hard to include in an existing test case because we need to: install squid -> create a subvol -> check the visibility flag -> upgrade to tentacle -> verify the visibility flag. I think this needs a separate sub-suite of its own.

@vshankar
Copy link
Contributor

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

hard to include in an existing test case because we need to: install squid -> create a subvol -> check the visibility flag -> upgrade to tentacle -> verify the visibility flag. I think this needs a separate sub-suite of its own.

OK. I think you can put it under fs:bugs with a similar flow for upgrade.

@dparmar18
Copy link
Contributor Author

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

hard to include in an existing test case because we need to: install squid -> create a subvol -> check the visibility flag -> upgrade to tentacle -> verify the visibility flag. I think this needs a separate sub-suite of its own.

OK. I think you can put it under fs:bugs with a similar flow for upgrade.

sure, i'll a new sub-suite under fs:bugs.

@vshankar
Copy link
Contributor

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

hard to include in an existing test case because we need to: install squid -> create a subvol -> check the visibility flag -> upgrade to tentacle -> verify the visibility flag. I think this needs a separate sub-suite of its own.

OK. I think you can put it under fs:bugs with a similar flow for upgrade.

sure, i'll a new sub-suite under fs:bugs.

Gentle nudge on this @dparmar18

@dparmar18
Copy link
Contributor Author

@vshankar should i also add an upgrade test case?

I think it's nice to have a test that verifies this change. We can include it in one of the existing fs:upgrade tests if possible.

hard to include in an existing test case because we need to: install squid -> create a subvol -> check the visibility flag -> upgrade to tentacle -> verify the visibility flag. I think this needs a separate sub-suite of its own.

OK. I think you can put it under fs:bugs with a similar flow for upgrade.

sure, i'll a new sub-suite under fs:bugs.

Gentle nudge on this @dparmar18

on it now

@github-actions github-actions bot added the tests label Nov 14, 2025
@dparmar18 dparmar18 force-pushed the i73550 branch 8 times, most recently from c3f5b6d to e25c9f3 Compare November 15, 2025 17:47
@dparmar18
Copy link
Contributor Author

@dparmar18 dparmar18 requested review from a team and vshankar November 15, 2025 18:24
@vshankar
Copy link
Contributor

@dparmar18 also check the jenkins failure regarding .qa links as qa code has been added in this change. The test checks is all there is a valid .qa symlink.

@dparmar18
Copy link
Contributor Author

@dparmar18 also check the jenkins failure regarding .qa links as qa code has been added in this change. The test checks is all there is a valid .qa symlink.

fixed

@vshankar
Copy link
Contributor

jenkins test docs

@vshankar
Copy link
Contributor

jenkins retest this please

@vshankar
Copy link
Contributor

This PR is under test in https://tracker.ceph.com/issues/73938.

@vshankar
Copy link
Contributor

vshankar commented Dec 1, 2025

Need to retest with https://tracker.ceph.com/issues/74026

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dparmar18 PTAL (unrelated failure due to another recent merge)

@dparmar18
Copy link
Contributor Author

…sibility flag

- If there is cluster upgrade, the older sr_t structs' flags would not have the
SNAPSHOT_VISIBILITY flag bit set which means the existing subvolumes would
report 0 instead of 1 for the vxattr ceph.dir.subvolume.snaps.visible which
although doesn't lead to any actual denial of access to subvolume snapshots
since the client config to respect snapshot visibility is set to false as
default but might come as a surprise to any cluster operator if the client
config is toggled to true to see the snapshot visibility being denied(since the
`flags` is reporting to be 0). So, change the in-memory flags while decoding
the sr_t members.
- bump up struct_v to 8 while encoding and while decoding, for all the structs older
than 8 be assigned SNAPSHOT_VISIBILITY flag in-memory accordingly.

Fixes: https://tracker.ceph.com/issues/73550
Signed-off-by: Dhairya Parmar <dparmar@redhat.com>
the default flag value should return 1

Fixes: https://tracker.ceph.com/issues/73550
Signed-off-by: Dhairya Parmar <dparmar@redhat.com>
@dparmar18
Copy link
Contributor Author

last push was a rebase

@dparmar18 dparmar18 requested a review from vshankar December 1, 2025 18:25
vshankar added a commit to vshankar/ceph that referenced this pull request Dec 2, 2025
* refs/pull/65960/head:

Reviewed-by: Venky Shankar <vshankar@redhat.com>
@vshankar vshankar self-assigned this Dec 2, 2025
Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vshankar vshankar merged commit ba6e1ce into ceph:main Dec 5, 2025
13 checks passed
@vshankar
Copy link
Contributor

https://tracker.ceph.com/projects/cephfs/wiki/QA_main_2025#wip-vshankar-testing-20251120083629-debug

Note that fs:upgrade fails currently due to reason mentioned in the above run wiki. However, I have tested this PR locally. Tests will be rerun when fs:upgrade issues is fixed with #66475

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cephfs Ceph File System tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants