No permission to modify the Google Cloud SDK installation


#1

Hi, I am trying to update Google Cloud SDK.

siaycclarence:~/workspace (master) $ gcloud components update

ERROR: (gcloud.components.update) You cannot perform this action because you do not have permission to modify the Google Cloud SDK installation directory [/usr/local/share/google/google-cloud-sdk].


#2

Re-run the command with sudo: sudo /usr/local/share/google/google-cloud-sdk/bin/gcloud components update

And it works!