テナントの共有を作成する
情報
USBストレージデバイスは、デフォルトでブロックされています。 USBデバイスへのアクセスが必要な場合は、管理者としてログインした後、CLI > tuning > configure を使用して、チューニングオプション cubesys.probeusb を true に設定してください。
共有サーバーを作成し、NFS/CIFS を使用して同じネットワーク上の他の VM とそのボリュームを共有する
プレタスク:
manila-service-image-master.qcow2を/mnt/cephfs/glanceにアップロードする- CLI を使用して
import_fsをインポートする
controller> image
controller:image> import_fs
1: usb
2: local
Enter index: 2
1: manila-service-image-master.qcow2
共有ネットワークを作成する
「プロジェクト」>「共有」>「共有ネットワーク」> + 共有ネットワークを作成


共有を作成 - テナント共有タイプ
「プロジェクト」>「共有」>「共有」> + 共有を作成 に移動します

- NFS または CIFS 共有プロトコルを作成する
- 共有サイズ = 10GB
- 共有タイプ = tenant_share_type
- 共有ネットワーク = share_network

ルールを作成する
「アクション」のドロップダウンボタンをクリックし、「ルールの管理」を選択してください

ルールを追加

VMのIPアドレスを入力してください

共有リンクを取得する
「プロジェクト」>「共有」>「共有」に移動し、「共有名」をクリックします

リンクをコピー

VMに共有フォルダをマウントする
インスタンスにSSH接続する
Warning: Permanently added '10.32.3.245' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-66-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Mon Nov 30 03:44:31 UTC 2020
System load: 0.06 Processes: 91
Usage of /: 9.3% of 19.21GB Users logged in: 0
Memory usage: 16% IP address for ens3: 192.168.10.105
Swap usage: 0%
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
* Canonical Livepatch is available for installation.
- Reduce system reboots and improve kernel security. Activate at:
https://ubuntu.com/livepatch
0 packages can be updated.
0 updates are security updates.
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
*** System restart required ***
Last login: Mon Nov 30 03:41:30 2020 from 10.32.4.1
ubuntu@ubuntu18:~$
[optional-ubuntu] nfs-common をインストール
ubuntu@ubuntu18:~$ sudo apt install nfs-common -y
フォルダを作成する
ubuntu@ubuntu18:~$ mkdir nfs-share
マウントアップ
ubuntu@ubuntu18:~$ sudo mount -t nfs 192.168.10.243:/shares/share-30363868-006d-41bf-8d4a-e21268d64ea2 nfs-share/
接続を確認
ubuntu@ubuntu18:~$ ls nfs-share/
lost+found
ubuntu@ubuntu18:~$ touch nfs-share/bigstack.co.txt
ubuntu@ubuntu18:~$ ls nfs-share/
bigstack.co.txt lost+found
ubuntu@ubuntu18:~$