External CephFS

janos

Member
Aug 24, 2017
156
14
23
Hungary
Hi,

I would like to mount an external CephFS, where the pool name is not cephfs.

With this command, i can mount it manually without any issue:

Code:
mount -t ceph MDSIP:6789:/ /mnt/test/cephfs -o mds_namespace=proxmoxfs -o name=proxmoxfs,secret=thesecrec
As you can see, the auth username is 'proxmoxfs', and the cephfs fs name also 'proxmoxfs'.

First i created the /etc/pve/priv/ceph/proxmoxfs.keyring file with the necessary content (client name and the key) and afteri tried to add it via the gui, it generate this entry in storage.cfg:

Code:
cephfs: proxmoxfs
        path /mnt/pve/proxmoxfs
        content snippets,backup,vztmpl,iso
        maxfiles 0
        monhost mon1;mon2;mon3
        username proxmoxfs
It not worked, and i see in dmesg this:

Code:
libceph: bad option at 'secretfile=/etc/pve/priv/ceph/cephfs.keyring'
Ok, the filename was wrong, i renamed my file to that, but it also not working.

After that i checkthe the PVE/Storage/CephFSPlugin.pm source, and in the cephfs_mount part, there is no option for custom pool name (mds_namespace).

Ok, no problem, i can overwrite this in /etc/ceph/ceph.conf with client_mds_namespace parameter.

Manual mounting now working without the mds_namespace option. But looks like from proxmox it not working.

I see only this in dmesg:
Code:
[ 6278.796418] libceph: no secret set (for auth_x protocol)
[ 6278.797233] libceph: error -22 on auth protocol 2 init
And i ran out of ideas. Off course, there is the workaround to mount it via fstab and add to proxmox as a folder.

And rename pool to cephfs unfornatelly not a solution, because there is a cephfs pool what used for kubernetes.
 

janos

Member
Aug 24, 2017
156
14
23
Hungary
I studied source, and looks like the secret need to be in the /etc/pve/priv/ceph/cephfs.secret file. However, currently the main issue, why mount not accept secretfile options.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE and Proxmox Mail Gateway. We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!