πŸ“’ Actions Speak Louder Than Words!

Setup SSH login without password

Posted: Dec 10, 2020 | Reading time: 1 min
⚠️ Warning: This post is over a year old, the information may be out of date.
πŸ“’ I’ve moved to a new website. Please visit me at https://journal.robbi.my !
post

# Currently on Windows with MingGW64 terminal
$ uname -a
MINGW64_NT-10.0-18363 AYAM-ITEK-KAMBING 3.1.6-340.x86_64 2020-07-09 14:33 UTC x86_64 Msys

# we must make sure the permissions to files and folders are correct
$ chmod 600 ~/.ssh/authorized_keys 
$ chmod 700 ~/.ssh/

# copy the public key contents from LOCAL MACHINE to REMOTE MACHINE
$ ssh-copy-id -i ~/.ssh/id_rsa.pub robbi@172.217.24.174 -p2222
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "~/.ssh/id_rsa.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted now it is to install the new keys

Number of key(s) added: 1

Now try logging into the machine, with:   "ssh -p '2222' 'robbi@172.217.24.174'"
and check to make sure that only the key(s) you wanted were added.

# try to ssh into remote machine
$ ssh robbi@172.217.24.174 -p 2222
Last login: Fri Dec 11 03:02:27 2020 from 10.0.2.2
[robbi@r0x ~]$ uname -a
Linux r0x 5.9.11-200.fc33.x86_64 #1 SMP Tue Nov 24 18:18:01 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
[robbi@r0x ~]$ cat /etc/fedora-release
Fedora release 33 (Thirty Three)

Edit

Have some thoughts, discussion or feedback on this post?
IndieWeb Interactions

Below you can find the interactions that this page has had using Indieweb. Which means, you can mentioned this URL on any website that support WebMention. Have you written a response to this post? Let me know the URL:

((Do you use a website that do not set up with WebMention capabilities? You can use Comment Parade.)


Mentions, bookmarks, likes and repost