【问题标题】:Creating an instance template in Google Cloud Platform from existing template从现有模板在 Google Cloud Platform 中创建实例模板
【发布时间】:2018-09-27 13:10:55
【问题描述】:

我正在尝试从现有模板创建新的实例模板,但总是出错。 我运行的命令:

gcloud compute instance-templates create elk-pool-template-us-west1-3 --source-instance elk-pool-template-us-west1-2 --source-instance-zone us-west1-2

我得到的错误:

错误:(gcloud.compute.instance-templates.create)无法识别的参数:

--源实例 elk-pool-template-us-west1-2

--源实例区域 us-west1-2

【问题讨论】:

  • 嗯,首先,您必须在--source-instance-zoneus-west1-2 is not one of them 中放置一个有效区域。也许你的意思是us-west1-a
  • 感谢您的回答,但我已经注意到它并且已修复仍然相同的错误
  • 我也试过 gcloud compute beta instance-templates create elk-pool-template-us-west1-3 --source-instance=gke-playground-pool-test-1-ef171324-5g3f -- source-instance-zone=us-west1-a

标签: google-cloud-platform google-compute-engine


【解决方案1】:

unrecognized-arguments 错误指出gcloud 无法识别的是--source-instance--source-instance-zone 参数,而不是您尝试分配的值。我刚刚尝试了你正在使用的命令,它对我有用,所以我认为你需要update the Cloud SDK

运行以下命令更新所有已安装的组件:

$ gcloud components update

【讨论】:

    猜你喜欢
    • 2017-05-23
    • 2017-02-02
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-03-25
    • 2021-05-15
    • 1970-01-01
    相关资源
    最近更新 更多