diff --git a/cmd/plugin/node_server.go b/cmd/plugin/node_server.go index b651a3f..c81ecd0 100644 --- a/cmd/plugin/node_server.go +++ b/cmd/plugin/node_server.go @@ -191,6 +191,11 @@ func (n NodeServer) NodeUnpublishVolume(ctx context.Context, req *csi.NodeUnpubl } mnt, err := n.k8smounter.IsMountPoint(req.TargetPath) + if !mnt || !os.IsNotExist(err) { + klog.Warningf("mount cleanup skipped: %s is not a mount point", req.TargetPath) + return &csi.NodeUnpublishVolumeResponse{}, nil + } + if err != nil || !mnt { return &csi.NodeUnpublishVolumeResponse{}, err }