Project

General

Profile

Documentation #57778

CephFS subvolume metadata not available in pacific

Added by Eugen Block 4 months ago. Updated 4 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
% Done:

0%

Tags:
Backport:
Reviewed:
Affected Versions:
Labels (FS):
Pull request ID:

Description

According to the current Pacific docs [1] it should be possible to set subvolume metadata for a cephfs volume:

Set custom metadata on the subvolume as a key-value pair using:

$ ceph fs subvolume metadata set <vol_name> <subvol_name> <key_name> <value> [--group_name <subvol_group_name>]

So I tried this:


pacific:~ # ceph versions
{
    "mon": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 3
    },
    "mgr": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 3
    },
    "osd": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 8
    },
    "mds": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 2
    },
    "rgw": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 2
    },
    "overall": {
        "ceph version 16.2.7-650-gd083eaa3886 (d083eaa388669167a5adf50446d1433de903d6f4) pacific (stable)": 18
    }
}

pacific:~ # ceph fs subvolume create cephfs subvol1 
pacific:~ # ceph fs subvolume ls cephfs
[
    {
        "name": "subvol1" 
    }
]

pacific:~ # ceph fs subvolume metadata ls 
no valid command found; 10 closest matches:
fs subvolume ls <vol_name> [<group_name>]
fs subvolume create <vol_name> <sub_name> [<size:int>] [<group_name>] [<pool_layout>] [<uid:int>] [<gid:int>] [<mode>] [--namespace-isolated]
fs subvolume rm <vol_name> <sub_name> [<group_name>] [--force] [--retain-snapshots]
fs subvolume authorize <vol_name> <sub_name> <auth_id> [<group_name>] [<access_level>] [<tenant_id>] [--allow-existing-id]
fs subvolume deauthorize <vol_name> <sub_name> <auth_id> [<group_name>]
fs subvolume authorized_list <vol_name> <sub_name> [<group_name>]
fs subvolume evict <vol_name> <sub_name> <auth_id> [<group_name>]
fs subvolume getpath <vol_name> <sub_name> [<group_name>]
fs subvolume info <vol_name> <sub_name> [<group_name>]
fs subvolume snapshot ls <vol_name> <sub_name> [<group_name>]
Error EINVAL: invalid command

pacific:~ # ceph fs subvolume metadata set cephfs subvol1 ebl-key ebl-value
no valid command found; 10 closest matches:
fs subvolume ls <vol_name> [<group_name>]
fs subvolume create <vol_name> <sub_name> [<size:int>] [<group_name>] [<pool_layout>] [<uid:int>] [<gid:int>] [<mode>] [--namespace-isolated]
fs subvolume rm <vol_name> <sub_name> [<group_name>] [--force] [--retain-snapshots]
fs subvolume authorize <vol_name> <sub_name> <auth_id> [<group_name>] [<access_level>] [<tenant_id>] [--allow-existing-id]
fs subvolume deauthorize <vol_name> <sub_name> <auth_id> [<group_name>]
fs subvolume authorized_list <vol_name> <sub_name> [<group_name>]
fs subvolume evict <vol_name> <sub_name> <auth_id> [<group_name>]
fs subvolume getpath <vol_name> <sub_name> [<group_name>]
fs subvolume info <vol_name> <sub_name> [<group_name>]
fs subvolume snapshot ls <vol_name> <sub_name> [<group_name>]
Error EINVAL: invalid command

In Quincy it works as expected:


quincy:~ # ceph fs subvolume metadata set cephfs subvol1 ebl-key ebl-value
quincy:~ # ceph fs subvolume metadata ls cephfs subvol1
{
    "ebl-key": "ebl-value" 
}

[1] https://docs.ceph.com/en/pacific/cephfs/fs-volumes/

History

#1 Updated by Venky Shankar 4 months ago

Hi Eugen,

The latest pacific (v16.2.10) only included CVE fixes as per

https://github.com/ceph/ceph/blob/main/doc/releases/pacific.rst

although the changes to support subvolume metadata

https://github.com/ceph/ceph/pull/45961

were already merged.

(I was away when .10 was released, so let me check more on this)

#2 Updated by Venky Shankar 4 months ago

Hi Eugen,

The doc changes are backported when a backport PR gets merged. The 16.2.10 release is a hotfix release which included just the CVE fixes, so, the doc changes were backported to the release, however, the change itself (for subvolume metadata) did not make it to the point release.

This is confusing for our users who would expect the functionality to be in place if its mentioned in the doc. Thanks for the bug report :)

I'll bring this up with the broader team soon. Sorry for the confusion again.

The subvolume metadata functionality would be available in 16.2.11.

Cheers,
Venky

#3 Updated by Eugen Block 4 months ago

Thanks for the update and looking into it. :-)

Also available in: Atom PDF