diff --git a/content/zh/docs/concepts/storage/volumes.md b/content/zh/docs/concepts/storage/volumes.md index 2d92dbf79cf7a..a3ceff9dc1399 100644 --- a/content/zh/docs/concepts/storage/volumes.md +++ b/content/zh/docs/concepts/storage/volumes.md @@ -256,22 +256,21 @@ For more details, see the [`azureDisk` volume plugin](https://github.com/kuberne --> #### azureDisk 的 CSI 迁移 {#azuredisk-csi-migration} -{{< feature-state for_k8s_version="v1.19" state="beta" >}} +{{< feature-state for_k8s_version="v1.24" state="stable" >}} 启用 `azureDisk` 的 `CSIMigration` 功能后,所有插件操作从现有的树内插件重定向到 `disk.csi.azure.com` 容器存储接口(CSI)驱动程序。 为了使用此功能,必须在集群中安装 [Azure 磁盘 CSI 驱动程序](https://github.com/kubernetes-sigs/azuredisk-csi-driver), -并且 `CSIMigration` 和 `CSIMigrationAzureDisk` 功能必须被启用。 +并且 `CSIMigration` 功能必须被启用。 Azure 文件 CSI 驱动尚不支持为同一卷设置不同的 fsgroup。 如果 AzureFile CSI 迁移被启用,用不同的 fsgroup 来使用同一卷也是不被支持的。 @@ -413,20 +413,20 @@ spec: --> #### OpenStack CSI 迁移 -{{< feature-state for_k8s_version="v1.21" state="beta" >}} +{{< feature-state for_k8s_version="v1.24" state="stable" >}} -Cinder 的 `CSIMigration` 功能在 Kubernetes 1.21 版本中是默认被启用的。 +Cinder 的 `CSIMigration` 功能从 Kubernetes 1.21 版本开始默认被启用。 此特性会将插件的所有操作从现有的树内插件重定向到 `cinder.csi.openstack.org` 容器存储接口(CSI)驱动程序。 为了使用此功能,必须在集群中安装 @@ -434,8 +434,9 @@ Cinder 的 `CSIMigration` 功能在 Kubernetes 1.21 版本中是默认被启用 你可以通过设置 `CSIMigrationOpenStack` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/) 为 `false` 来禁止 Cinder CSI 迁移。 -如果你禁用了 `CSIMigrationOpenStack` 功能特性,则树内的 Cinder 卷插件 -会负责 Cinder 卷存储管理的方方面面。 + +要禁止控制器管理器和 kubelet 加载树内 Cinder 插件, +你可以启用 `InTreePluginOpenStackUnregister` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。 ### configMap @@ -1601,15 +1602,15 @@ For more information about StorageOS, dynamic provisioning, and PersistentVolume 关于 StorageOS 的进一步信息、动态供应和持久卷申领等等,请参考 [StorageOS 示例](https://github.com/kubernetes/examples/blob/master/volumes/storageos)。 -### vsphereVolume {#vspherevolume} - +### vsphereVolume (已弃用) {#vspherevolume} + {{< note >}} -你必须配置 Kubernetes 的 vSphere 云驱动。云驱动的配置方法请参考 -[vSphere 使用指南](https://vmware.github.io/vsphere-storage-for-kubernetes/documentation/)。 +我们建议改用 vSphere CSI out-of-tree 驱动程序。 {{< /note >}} -{{< caution >}} -在挂载到 Pod 之前,你必须用下列方式之一创建 VMDK。 -{{< /caution >}} - - -#### 创建 VMDK 卷 {#creating-vmdk-volume} - -选择下列方式之一创建 VMDK。 - -{{< tabs name="tabs_volumes" >}} -{{% tab name="使用 vmkfstools 创建" %}} - -首先 ssh 到 ESX,然后使用下面的命令来创建 VMDK: - -```shell -vmkfstools -c 2G /vmfs/volumes/DatastoreName/volumes/myDisk.vmdk -``` -{{% /tab %}} -{{% tab name="使用 vmware-vdiskmanager 创建" %}} - -使用下面的命令创建 VMDK: - -```shell -vmware-vdiskmanager -c -t 0 -s 40GB -a lsilogic myDisk.vmdk -``` -{{% /tab %}} - -{{< /tabs >}} - - - -#### vSphere VMDK 配置示例 {#vsphere-vmdk-configuration} - -```yaml -apiVersion: v1 -kind: Pod -metadata: - name: test-vmdk -spec: - containers: - - image: k8s.gcr.io/test-webserver - name: test-container - volumeMounts: - - mountPath: /test-vmdk - name: test-volume - volumes: - - name: test-volume - # 此 VMDK 卷必须已经存在 - vsphereVolume: - volumePath: "[DatastoreName] volumes/myDisk" - fsType: ext4 -``` - @@ -1701,6 +1640,8 @@ from the existing in-tree plugin to the `csi.vsphere.vmware.com` {{< glossary_to [vSphere CSI driver](https://github.com/kubernetes-sigs/vsphere-csi-driver) must be installed on the cluster and the `CSIMigration` and `CSIMigrationvSphere` [feature gates](/docs/reference/command-line-tools-reference/feature-gates/) must be enabled. +You can find additional advice on how to migrate in VMware's +documentation page [Migrating In-Tree vSphere Volumes to vSphere Container Storage Plug-in](https://docs.vmware.com/en/VMware-vSphere-Container-Storage-Plug-in/2.0/vmware-vsphere-csp-getting-started/GUID-968D421F-D464-4E22-8127-6CB9FF54423F.html). --> 当 `vsphereVolume` 的 `CSIMigration` 特性被启用时,所有插件操作都被从树内插件重定向到 `csi.vsphere.vmware.com` {{< glossary_tooltip text="CSI" term_id="csi" >}} 驱动。 @@ -1708,12 +1649,20 @@ must be installed on the cluster and the `CSIMigration` and `CSIMigrationvSphere [vSphere CSI 驱动](https://github.com/kubernetes-sigs/vsphere-csi-driver),并启用 `CSIMigration` 和 `CSIMigrationvSphere` [特性门控](/zh/docs/reference/command-line-tools-reference/feature-gates/)。 +你可以在 VMware 的文档页面 [Migrating In-Tree vSphere Volumes to vSphere Container Storage Plug-in](https://docs.vmware.com/en/VMware-vSphere-Container-Storage-Plug-in/2.0/vmware-vsphere-csp-getting-started/GUID-968D421F-D464-4E22-8127-6CB9FF54423F.html) +中找到有关如何迁移的其他建议。 -此特性还要求 vSphere vCenter/ESXi 的版本至少为 7.0u1,且 HW 版本至少为 -VM version 15。 +Kubernetes v{{< skew currentVersion >}} 要求你使用 vSphere 7.0u2 或更高版本才能迁移到树外 CSI 驱动程序。 +如果你正在运行 v{{< skew currentVersion >}} 以外的 Kubernetes 版本,请查阅该 Kubernetes 版本的文档。 +如果你正在运行 Kubernetes v{{< skew currentVersion >}} 和旧版本的 vSphere,请考虑至少升级到 vSphere 7.0u2。 {{< note >}} @@ -1995,7 +1943,6 @@ if the driver supports that (beta feature) * 通过 PersistentVolumeClaim(#persistentvolumeclaim) 对象引用 * 使用[一般性的临时卷](/zh/docs/concepts/storage/ephemeral-volumes/#generic-ephemeral-volume) - (Alpha 特性) * 使用 [CSI 临时卷](/zh/docs/concepts/storage/ephemeral-volumes/#csi-ephemeral-volume), 前提是驱动支持这种用法(Beta 特性)