如何在Linux/Unix/OS X上更新gcutil/gcloud组件
时间:2020-01-09 10:40:47 来源:igfitidea点击:
如何在基于Linux或OS X Unix的系统上更新Google Cloud SDK组件?
最简单推荐的方法是使用gcloud命令更新各种Google Cloud SDK库,命令和其他组件。
当您在屏幕上看到以下消息时,请打开终端并输入以下命令:There are available updates for some Cloud SDK components某些Cloud SDK组件有可用更新。
更新gcloud组件的命令如下:
gcloud components update
输出示例:
The following components will be removed:
---------------------------------------------------------------------
| Big Query Command Line Tool | 2.0.17 | 1.3 MB |
| Cloud SDK Core Libraries | 2013.12.06 | < 1 MB |
| Cloud SDK Core Libraries (Platform Specific) | 2013.11.19 | < 1 MB |
| Cloud Storage Command Line Tool | 3.38 | 1.7 MB |
| Compute Engine Command Line Tool | 1.12.0 | < 1 MB |
---------------------------------------------------------------------
The following components will be installed:
-----------------------------------------------------------------------------
| Big Query Command Line Tool | 2.0.17 | < 1 MB |
| Big Query Command Line Tool (Platform Specific) | 2.0.17 | < 1 MB |
| Cloud SDK Core Libraries | 2014.01.27 | < 1 MB |
| Cloud SDK Core Libraries (Platform Specific) | 2014.01.27 | < 1 MB |
| Cloud SQL Admin Command Line Interface | 2014.01.28 | < 1 MB |
| Cloud Storage Command Line Tool | 3.42 | 1.8 MB |
| Cloud Storage Command Line Tool (Platform Specific) | 3.42 | < 1 MB |
| Compute Engine Command Line Tool | 1.13.0 | < 1 MB |
| Compute Engine Command Line Tool (Platform Specific) | 1.13.0 | < 1 MB |
-----------------------------------------------------------------------------
Do you want to continue (Y/n)? y
Creating update staging area...
Uninstalling: Big Query Command Line Tool ... Done
Uninstalling: Cloud SDK Core Libraries ... Done
Uninstalling: Cloud SDK Core Libraries (Platform Specific) ... Done
Uninstalling: Cloud Storage Command Line Tool ... Done
Uninstalling: Compute Engine Command Line Tool ... Done
Installing: Big Query Command Line Tool ... Done
Installing: Big Query Command Line Tool (Platform Specific) ... Done
Installing: Cloud SDK Core Libraries ... Done
Installing: Cloud SDK Core Libraries (Platform Specific) ... Done
Installing: Cloud SQL Admin Command Line Interface ... Done
Installing: Cloud Storage Command Line Tool ... Done
Installing: Cloud Storage Command Line Tool (Platform Specific) ... Done
Installing: Compute Engine Command Line Tool ... Done
Installing: Compute Engine Command Line Tool (Platform Specific) ... Done
Creating backup and activating new installation...
Done!
请注意,更新SDK时,最终可能会丢失活动帐户的凭据。
要激活现有的用户帐户,请使用以下命令
$ gcloud auth login
只需按照屏幕上的说明进行操作即可。
使用以下命令SSH到Google Cloud Host:
$ gcutil ssh your-compute-name-here $ gcutil ssh db2

