【问题标题】:gsutil getting stuck and asking for authenticationgsutil 卡住并要求身份验证
【发布时间】:2015-04-11 10:14:25
【问题描述】:

我正在尝试从我的 Windows 机器(已经设置,并且我经常将它用于 gsutil)复制一个文件来复制一个文件,但它一直告诉我我正在尝试访问受保护的数据没有配置凭据。 不过,昨天运行良好。

E:\studioProjects3\demo\rsalib\build\libs>gsutil cp rsalib-1.0.jar gs://dark-b
lade-365.appspot.com
Copying file://rsalib-1.0.jar [Content-Type=application/octet-stream]...
Uploading   gs://dark-blade-365.appspot.com/rsalib-1.0.jar:      0 B/4.14 KiB
Uploading   gs://dark-blade-365.appspot.com/rsalib-1.0.jar:      4.14 KiB/4.14 K
iB
You are attempting to access protected data with no configured
credentials. Please visit https://cloud.google.com/console#/project
and sign up for an account, and then run the "gcloud auth login"
command to configure gsutil to use these credentials.

E:\studioProjects3\demo\rsalib\build\libs>gsutil acl get gs://dark-blade-365.a
ppspot.com
You are attempting to access protected data with no configured
credentials. Please visit https://cloud.google.com/console#/project
and sign up for an account, and then run the "gcloud auth login"
command to configure gsutil to use these credentials.

我 100% 确定我拥有这个项目/存储桶,它会显示在我的开发者控制台上。

到目前为止我已经尝试过:

  • 运行 gcloud auth login 以获取新令牌。我已经多次这样做了,但仍然给了我同样的错误。
  • 已尝试确保该项目与存储桶相同,而不是我设置的第二个项目对存储桶具有“授权访问”权限。
  • 尝试重启我的机器以防出现环境问题
  • 尝试 gcloud auth revoke,然后再次 gcloud auth login

这些都没有解决我的问题。这是 gcloud auth list 显示的内容:

E:\studioProjects3\demo\rsalib\build\libs>gcloud auth list
Credentialed accounts:
 - yaraju@gmail.com (active)

To set the active account, run:
  $ gcloud config set account ``ACCOUNT''

请帮我弄清楚这里发生了什么。

【问题讨论】:

    标签: google-cloud-storage gsutil


    【解决方案1】:

    gsutil 在 C: 中运行良好。但是如果我从 E:\ 运行它,它就会卡住并给我那个可怕的错误信息。

    修复: 只需从 C:\ 上的任何路径运行 gsutil,然后将绝对路径提供给您想要从/到传输的任何本地路径。

    【讨论】:

    • 只是为您的答案添加一些信息:这是一个known issue,将来应该修复。同时,正如您所说,解决方法是在 C:\ 下运行命令
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-12-02
    • 1970-01-01
    • 1970-01-01
    • 2013-05-30
    • 2018-06-06
    • 1970-01-01
    • 2014-08-07
    相关资源
    最近更新 更多