Actually I already have tried everything as dicussed in SSH Permission denied (publickey) and Unable to ssh to GCE: “Permission denied (publickey), But none resolved the issue.
I am able to ssh into root account, but not the account I used to login in.
I did try the following things to get it fixed from ROOT Account.
sudo chown -R $USER ~/.config/gcloud
Generate ssh key using the following commands
- Copy the key.pub file contents
- Append the contents to
sudo nano ~/.ssh/authorized_keys
I have set up Google cloud Virtual Machine Instance with Ubuntu 16.04 LTS. I usually use to ssh my machine with the following command:
gcloud compute --project "XXX-XXX" ssh --zone "us-east1-b" "XXXXXXXX"
But now when try it, it gives the following error:
Permission denied, please try again.
I have three accounts on virtual machine. One root, abdullah, mrafique.bese_17seecs. My whole virtual environments are existing in 'abdullah', which I cannot access right now.