【问题标题】:Is it possible to specifiy the boot disk type for a node pool?是否可以为节点池指定引导磁盘类型?
【发布时间】:2017-09-12 09:05:42
【问题描述】:

我正在尝试使用 gcloud 从 SSD 引导机器创建一个节点池。如果我尝试创建一个计算实例,我会使用 --boot-disk-type 选项来指定它,但在创建节点池时似乎没有这样的选项。

我检查了documentation on creating node-pools 并尝试像这样指定--boot-disk-type 选项:

gcloud container node-pools create test-pool --cluster=my-cluster --machine-type=n1-highcpu-4 --disk-size=50 --num-nodes=2 --boot-disk-type=pd-ssd

两者都没有成功。所以我的问题是,是否甚至可以使用从 SSD 引导的机器创建节点池。也许我试图以错误的方式做到这一点。如果这不受支持,有什么可能的解决方法来获得一个节点池,其中机器从 SSD 启动?


我知道我可以使用 --local-ssd-count 选项将本地 SSD 添加到计算机。然而这似乎并没有解决我的问题。

【问题讨论】:

    标签: google-cloud-platform gcloud google-kubernetes-engine


    【解决方案1】:

    现在支持此选项。您可以为节点池指定启动磁盘类型和大小。

    --disk-type=DISK_TYPE
        Type of the node VM boot disk. Defaults to pd-standard. DISK_TYPE must be one of: pd-standard, pd-ssd.
    
    --disk-size=DISK_SIZE
        Size for node VM boot disks. Defaults to 100GB.
    

    https://cloud.google.com/sdk/gcloud/reference/container/node-pools/create

    【讨论】:

      【解决方案2】:

      目前没有为节点池指定引导磁盘类型的选项。您可以为节点指定的选项记录在 Google Container Engine API 的 NodeConfig 结构中。

      顺便说一句,对于托管实例组中存在但 Google Container Engine API 中不存在的字段,您可以使用发布的解决方法here,但请注意,您的更改不会在节点版本升级中“粘滞”。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2019-11-27
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2019-11-08
        • 2019-12-18
        • 1970-01-01
        相关资源
        最近更新 更多