This documentation is for a release that is no longer maintained
See documentation for the latest supported version 3 or the latest supported version 4.4.3. Azure File を使用した永続ストレージ
OpenShift Container Platform では、Microsoft Azure File ボリュームがサポートされます。Azure を使用して、OpenShift Container Platform クラスターに永続ストレージをプロビジョニングできます。これには、Kubernetes と Azure についてのある程度の理解があることが前提となります。
Kubernetes 永続ボリュームフレームワークは、管理者がクラスターのプロビジョニングを永続ストレージを使用して実行できるようにし、ユーザーが基礎となるインフラストラクチャーの知識がなくてもこれらのリソースを要求できるようにします。Azure File ボリュームを動的にプロビジョニングできます。
永続ボリュームは、単一のプロジェクトまたは namespace にバインドされず、OpenShift Container Platform クラスター全体で共有できます。永続ボリューム要求 (PVC) はプロジェクトまたは namespace に固有のもので、アプリケーションで使用できるようにユーザーによって要求されます。
インフラストラクチャーにおけるストレージの高可用性は、基礎となるストレージのプロバイダーに委ねられています。
Azure File ボリュームは Server Message Block を使用します。
4.3.1. Azure File 共有永続ボリューム要求 (PVC) の作成 リンクのコピーリンクがクリップボードにコピーされました!
永続ボリューム要求 (PVC) を作成するには、最初に Azure アカウントおよびキーを含む Secret
オブジェクトを定義する必要があります。このシークレットは PersistentVolume
定義に使用され、アプリケーションで使用できるように永続ボリューム要求 (PVC) によって参照されます。
前提条件
- Azure File 共有があること。
- この共有にアクセスするための認証情報 (とくにストレージアカウントおよびキー) が利用可能であること。
手順
Azure File の認証情報が含まれる
Secret
オブジェクトを作成します。oc create secret generic <secret-name> --from-literal=azurestorageaccountname=<storage-account> \ --from-literal=azurestorageaccountkey=<storage-account-key>
$ oc create secret generic <secret-name> --from-literal=azurestorageaccountname=<storage-account> \
1 --from-literal=azurestorageaccountkey=<storage-account-key>
2 Copy to Clipboard Copied! Toggle word wrap Toggle overflow 作成した
Secret
オブジェクトを参照するPersistentVolume
を作成します。Copy to Clipboard Copied! Toggle word wrap Toggle overflow 作成した永続ボリュームにマップする
PersistentVolumeClaim
オブジェクトを作成します。Copy to Clipboard Copied! Toggle word wrap Toggle overflow