0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Google Compute EngineでSSH認証鍵がauthorized_keysに追加されない

Posted at

SSHの認証鍵が登録されない

Google Cloud Console上のSSH認証鍵に公開鍵を登録しているのにも関わらず、Compute Engineのauthorized_keysに鍵が登録されない。その原因の解決に苦労したのでメモをしておく。

解決策

公開鍵のusernameをcompute engineのユーザー名に変更する必要がある。
公式ドキュメントを参考にすると
公開鍵の登録は鍵の値とユーザー名となっている

KEY_VALUE USERNAME

となっており、USERNAMEをcompute engine上のusername(@よりも前のやつ username@instance-11111)に変える必要がある。そうしないと、authorized_keysに追加されない。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?