You can create a Persistent Volume Claim (PVC) by using the Container Service console.
- You have created a Kubernetes cluster. For more information, see Create an ACK cluster.
- You have created a volume. In this example, use a cloud disk to create a cloud storage
volume. For more information, see Use Alibaba Cloud disks as volumes.
By default, the storage claim is bound to the storage volume depending on the label alicloud-pvname. When the data volume is created by using the Container Service console, the storage volume is labeled by default. If the storage volume label does not exist, you must add a label before you select to bound this storage volume.
- Log on to the Container Service console.
- Under Kubernetes, click in the left-side navigation pane to enter the Volumes Claims list page.
- Select the target cluster and namespace, and click Create in the upper-right corner.
- Complete the configurations in the Create Volume Claim dialog box, and click Create.
Note If a storage volume already exists in your cluster and is not used, but cannot be found in Select Existing Storage Volume, maybe the alicloud-pvname label is not defined.If you cannot find an available storage volume, you can click Label Management on the right. Add the corresponding label alicloud-pvname, the value is the name of the storage volume. The cloud storage volume defaults to the cloud disk ID as the name of the storage volume.in the left-side navigation pane. Find the target storage volume, click
- Volume claim type: Consistent with volume, including cloud disk, NAS, and OSS types.
- Name: Enter the storage volume claim name.
- Distribution mode: Currently, only existing storage volumes are supported.
- Existing storage volume: Select to bind the storage volume of this type.
- Total: Claim usage, cannot be greater than the total amount of storage volumes.
- Return to the Volumes Claims list, you can see that the newly created storage claim appears in the list.