【发布时间】:2017-11-14 19:11:51
【问题描述】:
我关注了 Google Pub/Sub 快速入门 guide。当我尝试运行 gcloud components install beta 时,出现以下错误。
ERROR: (gcloud.components.install) Permission denied:
[/usr/local/google-cloud-sdk.staging]
Ensure you have the permissions to access the file and that the file is not in use.
我该如何解决这个问题?
【问题讨论】:
-
你试过sudo命令吗?您可能没有写入该文件夹的权限。
sudo gcloud components install beta -
这样就解决了。我觉得很愚蠢。
-
不用担心,很高兴您成功了!
-
我在运行
glcoud components update时遇到了同样的问题。不知道为什么我最初运行gcloud components install时没有遇到这个问题。但是@MatthiasBaetens 解决方案对我有用。请提交作为答案马蒂亚斯。 -
感谢@MichaelOsofsky 的反馈 - 答案就在眼前!