【问题标题】:Getting error on kubectl get nodes commandkubectl get nodes 命令出错
【发布时间】:2019-08-31 22:47:21
【问题描述】:

运行以下命令时出现错误。我已经更新了 gcloud SDK,但仍然遇到同样的错误。

kubectl get nodes


Unable to connect to the server: error executing access token command "/Users/salayhin/google-cloud-sdk/bin/gcloud config config-helper --format=json": err=exit status 1 output= stderr=Traceback (most recent call last):
  File "/Users/salayhin/google-cloud-sdk/lib/gcloud.py", line 95, in <module>
    main()
  File "/Users/salayhin/google-cloud-sdk/lib/gcloud.py", line 54, in main
    from googlecloudsdk.core.util import encoding
  File "/Users/salayhin/google-cloud-sdk/lib/googlecloudsdk/__init__.py", line 23, in <module>
    from googlecloudsdk.core.util import lazy_regex
  File "/Users/salayhin/google-cloud-sdk/lib/googlecloudsdk/core/util/lazy_regex.py", line 25, in <module>
    from googlecloudsdk.core.util import lazy_regex_patterns
ImportError: cannot import name lazy_regex_patterns

【问题讨论】:

  • 不幸的是,我认为这个问题来自 Python 客户端库,而不是来自 Google Cloud SDK。
  • 能否请您提供安装了google cloud SDK的linux系统?
  • @MdSirajusSalayhin 如果有助于解决问题,您能否将答案标记为已批准?

标签: kubernetes gcloud kubectl


【解决方案1】:

这似乎只是来自 Google Cloud SDK 的错误here,表明您可能在同一目录中缺少this file

我建议在您使用的任何系统上重新安装Google Cloud SDK

【讨论】:

    猜你喜欢
    • 2019-04-02
    • 2021-11-05
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-11-29
    • 2021-10-06
    • 2016-11-11
    相关资源
    最近更新 更多