• Skip to main content

Uly.me

cloud engineer

  • Home
  • About
  • Archives

Invalid Credentials with gsutil

April 16, 2021

If you’re trying to access GCS (Google Cloud Storage) and you’re getting “Your credentials are invalid. Please run gcloud auth login”, you most likely have a previous key stored in the ~/.boto file. This happens if you previously configured gsutil with your own credentials, then switched over to Google SDK mode. To fix the invalid credentials, edit the ~/.boto file and comment out the auth key.

vim ~/.boto

vim ~/.boto

Comment out.

#gs_oauth2_refresh_token = <token redacted>

#gs_oauth2_refresh_token = <token redacted>

Rerun the gsutil ls command. It should work.

Filed Under: Cloud Tagged With: .boto, auth, gcp, invalid, login, service account, token

Search This Website

Subscribe Via Email

  • Home
  • About
  • Archives

Copyright © 2023