k8s无法在GCP上调度本地ssd卷

时间:2018-09-06 08:11:45

标签: kubernetes google-kubernetes-engine

我正在尝试将Google Cloud中的本地SSD指定为MainNavigationController。我按照docs设置了automated SSD provisioning,运行PersistedVolume返回了一个有效的卷:

kubectl get pv

问题是我无法使吊舱绑定到它。 NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS REASON AGE local-pv-9721c951 368Gi RWO Delete Available local-scsi 1h 持续显示以下内容:

kubectl get pvc

NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE mapdata Pending local-scsi 7m 给了我这些:

kubectl get events

我需要怎么做才能将该SSD绑定到我的Pod?这是我一直在尝试的代码:

LAST SEEN   FIRST SEEN   COUNT     NAME                                                KIND                    SUBOBJECT   TYPE      REASON                 SOURCE                        MESSAGE
7m          7m           1         v3tiles.1551c0bbcb23d983                            Service                             Normal    EnsuredLoadBalancer    service-controller            Ensured load balancer
2m          8m           24        maptilesbackend-8645566545-x44nl.1551c0ae27d06fca   Pod                                 Warning   FailedScheduling       default-scheduler             0/1 nodes are available: 1 node(s) didn't find available persistent volumes to bind.
2m          8m           26        mapdata.1551c0adf908e362                            PersistentVolumeClaim               Normal    WaitForFirstConsumer   persistentvolume-controller   waiting for first consumer to be created before binding

2 个答案:

答案 0 :(得分:3)

ReadOnlyMany对于本地SSD没有意义

根据文档:

  

ReadOnlyMany –该卷可以被许多节点只读装载

您不能在多个节点上安装本地SSD,因为它仅在一个节点上本地。

答案 1 :(得分:0)

事实证明,accessMode: ReadOnlyMany在这种情况下不起作用。不确定如何使其运作...如果我找到更多信息,将会发布。