Error: "ControllerPublishVolume: Volume capability does not have mount capabilities set" trying to create a PVC with volumeMode: Block
search cancel

Error: "ControllerPublishVolume: Volume capability does not have mount capabilities set" trying to create a PVC with volumeMode: Block

book

Article ID: 442523

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • When you try to create a PVC with "volumeMode: Block" in Container service extension (CSE) in VMware Cloud Director (VCD) the operation fails.
  • The Kubernetes Container Storage Interface Driver for VCD (CSI) controller logs or describe events for the PVC shows a similar error:

    GRPC error: function [/csi.v1.Controller/ControllerPublishVolume] req [...]: [rpc error: code = InvalidArgument desc = ControllerPublishVolume: Volume capability does not have mount capabilities set]
  • When you try to Mount a named disk as a block device you get an error like the one above.

Environment

VMware Cloud Director 10.6.x

Kubernetes Container Storage Interface Driver for VCD 1.6

VMware Cloud Director Container Service Extension 4.x

 

Cause

This issue occurs because the VMware Cloud Director CSI Driver v1.6.0 does not support Raw Block Volumes.

Resolution

This is a known limitation in CSI 1.6, currently there is no resolution.

The driver only supports "volumeMode: Filesystem". For more information about CSI cababilities you can check this link: Features