-1

I created a Debian VM in the Google Cloud, clicked on SSH from the GCP interface. A console shell opened, no problem, I'm logged in. Now I want to use sudo: it asks me for my current password. What is my password? Also, what is the root password?

nicomp
  • 4,344
  • 4
  • 27
  • 60

1 Answers1

2

The user account created by Google Compute Engine doesn't set a password. As an implication it is impossible to use sudo and most screen-locking apps can't unlock. To set password follow steps from the documentation:

  1. Connect to the instance using SSH, as you did when you first set up the instance. Here is the documentation how to connect using SSH.
  2. Create a password for the user: sudo passwd $(whoami)

Please note that this password will be also used on the screen lock.

Pawel Czuczwara
  • 1,442
  • 9
  • 20