22
0
Fork 0

Ajout ceph-fuse

This commit is contained in:
abenmiloud 2018-05-25 14:49:26 +02:00
parent a859f86868
commit dc99863f7f
1 changed files with 13 additions and 3 deletions

View File

@ -438,7 +438,7 @@ Il suffit de monter le CephFS, il sera utilisable :
~~~
$ KEY=$(awk '/key/ { print $NF }' </etc/ceph/ceph.client.admin.keyring)
$ mkdir /mnt/mycephfs
$ mount.ceph $CEPH_MON:/ /mnt/mycephfs/ -o 'name=admin,secret=$KEY'
$ mount.ceph $MONITOR_IP_ADDRESS:/ /mnt/mycephfs/ -o 'name=admin,secret=$KEY'
$ cat <<EOF >/mnt/mycephfs/truth
slackware is the best
e ≃ 2.7181828
@ -447,10 +447,20 @@ EOF
On peut aussi utiliser FUSE :
**TODO** FUSE et sudo ?
~~~
ceph-fuse -m $MONITOR_IP_ADDRESS:6789 /mnt/mycephfs
~~~
Il est également possible de limiter l'utilisation du FS à un répertoire pour un utilisateur Ceph :
~~~
$ ceph-fuse -k /path/to/ceph.client.admin.keyring -m $CEPH_MON:6789 ~/mycephfs
ceph fs authorize cephfs client.cephuser /dir0 rw /dir1 r
~~~
Cette commande va créer un utilisateur `client.cephuser`. Il aura accès au répertoire `/dir0` en lecture et en écriture et `/dir1` en lecture seule. On pourra monter le FS de cette manière :
~~~
ceph-fuse -m $MONITOR_IP_ADDRESS:6789 /mnt/mycephfs/ -r /dir0
~~~