<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>FYI, when I have followed the instructions for setting up ssh
passwordless login using ssh-kgen given at the link below, it has
always gone well for me:</p>
<p><a class="moz-txt-link-freetext" href="https://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/">https://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/</a><br>
</p>
<p>First, you might want to check if you have the following files
and file permissions similar to:<br>
</p>
<p><font color="#999999">username@computername:~$</font> ls -al
~/.ssh<br>
<font color="#999999">total 24<br>
drwx------ 2 username username 4096 Oct 28 23:54 .<br>
drwxr-xr-x 68 username username 4096 Oct 28 23:54 ..<br>
-rw-rw-r-- 1 username username 401 Oct 28 23:54
authorized_keys<br>
-rw------- 1 username username 1679 Oct 28 23:50 id_rsa<br>
-rw-r--r-- 1 username username 401 Oct 28 23:50 id_rsa.pub<br>
-rw-r--r-- 1 username username 222 Oct 28 23:47 known_hosts</font><br>
</p>
<p>Second, you might try removing all the files in .ssh to start
over:</p>
<p><font color="#999999">username@computername:~$</font> rm ~/.ssh/*<br>
</p>
<p>After removing all the files in the .ssh folder, it prompts me
again for my password:<br>
</p>
<p><font color="#999999">username@computername:~$</font> ssh
localhost<br>
<font color="#999999">The authenticity of host 'localhost
(127.0.0.1)' can't be established.<br>
ECDSA key fingerprint is blah blah.<br>
Are you sure you want to continue connecting (yes/no)?</font>
yes<br>
<font color="#999999">Warning: Permanently added 'localhost'
(ECDSA) to the list of known hosts.<br>
<font color="#009900">username@localhost's password:</font> <br>
... <br>
Last login: Sun Oct 28 23:39:38 2018 from 127.0.0.1<br>
username@computername:~$</font> exit<br>
<font color="#999999">...</font></p>
<p>Next, I setup the ssh-keygen on the client hostname (e.g.
localhost), then I copy authorized_keys to the remote hostname
(e.g., localhost <- Usually, this has to be done using the
hostname for each of your nodes. In this case, it only has to be
done once and it connects back to the same localhost.):<br>
</p>
<p><font color="#999999">username@computername:~$</font> ssh-keygen
-t rsa<br>
<font color="#999999">Generating public/private rsa key pair.<br>
Enter file in which to save the key
(/home/username/.ssh/id_rsa): <br>
Enter passphrase (empty for no passphrase): <br>
Enter same passphrase again: <br>
Your identification has been saved in
/home/username/.ssh/id_rsa.<br>
Your public key has been saved in
/home/username/.ssh/id_rsa.pub.<br>
The key fingerprint is:<br>
blah blah username@computername<br>
The key's randomart image is:<br>
+---[RSA 2048]----+<br>
| o o |<br>
| () |<br>
| |<br>
| |<br>
| |<br>
| |<br>
| |<br>
| |<br>
| |<br>
+----[SHA256]-----+<br>
</font></p>
<p><font color="#999999">username@computername:~$</font> cat
~/.ssh/id_rsa.pub | ssh localhost 'cat >>
~/.ssh/authorized_keys'<br>
<font color="#999999"><font color="#009900">username@localhost's
password:</font> <br>
</font><font color="#999999">username@computername:~$</font> exit<br>
<font color="#999999">logout<br>
Connection to localhost closed.</font><br>
</p>
<p><font color="#999999"><font color="#000000">It works as it no
longer prompts for a password (i.e., it no longer stops with "<font
color="#009900">username@localhost's password:</font>" when
connecting):</font><br>
</font></p>
<p><font color="#999999">username@computername:~$</font> ssh
localhost<br>
<font color="#999999">...<br>
<br>
Last login: Sun Oct 28 23:49:28 2018 from 127.0.0.1</font><br>
<font color="#999999"><font color="#999999">username@computername:~$</font><font
color="#000000"> exit</font></font></p>
<p><font color="#999999"><font color="#000000">Finally, "ls -al
~/.ssh" gives the files and file permissions that were first
shown above.</font></font><br>
</p>
<div class="moz-cite-prefix">On 10/28/2018 9:53 AM, Peter Blaha
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:2f10b603-ba56-0a4d-c215-9ce099ec55d8@theochem.tuwien.ac.at">Remove
the config file.
<br>
<br>
Your username seems to be: User
<br>
<br>
You don't want a user localhost
<br>
<br>
localhost is the hostname, not the username.
<br>
<br>
<br>
-------- Weitergeleitete Nachricht --------
<br>
Betreff: [RE]Re: [Wien] Fail to parallel calculation of lapw1
and lapw2 (testpara1 and testpara2)
<br>
Datum: Mon, 29 Oct 2018 00:48:47 +0900 (KST)
<br>
Von: Woohyeon Baek <a class="moz-txt-link-rfc2396E" href="mailto:wh8426@knu.ac.kr"><wh8426@knu.ac.kr></a>
<br>
An: <a class="moz-txt-link-abbreviated" href="mailto:pblaha@theochem.tuwien.ac.at">pblaha@theochem.tuwien.ac.at</a>
<br>
<br>
<br>
<br>
Dear Peter Blaha,
<br>
<br>
<br>
I set 'User localhost' in config file.
<br>
<br>
<br>
Sorry, I mistyped authorized_keys as key_authorized in mailing.
<br>
<br>
<br>
Anyway I retried
<br>
<br>
<br>
1. ssh-keygen –t rsa
<br>
2 .append .ssh/authorized_keys on remote host with id_rsa.pub of
local host
<br>
<br>
<br>
In 'Installation of Wien2k, parallelization, large scale
applications with WIEN2k' your presentation file.
<br>
<br>
<br>
But it still requires password.
<br>
<br>
-----------------------------------
<br>
<br>
[User@localhost .ssh]$ ssh localhost
<br>
<a class="moz-txt-link-abbreviated" href="mailto:localhost@127.0.0.1">localhost@127.0.0.1</a>'s <a class="moz-txt-link-rfc2396E" href="mailto:localhost@127.0.0.1's"><mailto:localhost@127.0.0.1's></a>
password:
<br>
<br>
------------------------------------
<br>
<br>
<br>
Are there any more steps that I need to perform?
<br>
<br>
<br>
<br>
Sincerely,
<br>
<br>
<br>
Woohyeon Baek
<br>
</blockquote>
<br>
</body>
</html>