Re: passwordless login with same user id across box
- From: "Vladimir Levijev" <vladimir.levijev@xxxxxxxxx>
- Date: Mon, 8 Dec 2008 13:07:33 +0200
2008/12/7 Dilip M <dilipm79@xxxxxxxxx>:
Hi,
My first post to this list....after googling the web to find the
solution.
I have 2 box. One running Redhat (OpenSSH_3.9p1, OpenSSL 0.9.7a Feb 19
2003) and other Ubuntu(OpenSSH_4.6p1 Debian-5build1, OpenSSL 0.9.8e 23
Feb 2007).
I am trying to do password less login _from_ redhat _to_ ubuntu box. It
works for different user ID, but not for same user id.
i.e If user_A@redhat ssh's to user_B@ubuntu, it works.
But when, user_A@redhat ssh'd to user_A@ubuntu, it doesn't work.
PS: Home directory is common across box. (NIS ID's)
---log ---
$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/dilipm/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/dilipm/.ssh/id_rsa.
Your public key has been saved in /home/dilipm/.ssh/id_rsa.pub.
The key fingerprint is:
d4:db:36:3a:dd:9e:6d:c0:31:4a:75:d9:b9:9d:9d:c2 dilipm@blrmputest1
$cat id_rsa.pub >> authorized_keys
You are doing it on a server, right?
I usually perform next steps to setup a passwordless login (all
commands done on a client side, that is where you are connecting from,
in your case "user" is the same that you are logged in on a client):
$ ssh-keygen -t dsa -N '' -b 1024
$ ssh-copy-id -i ~/.ssh/id_dsa.pub user@remotebox
In case there is no ssh-copy-id (for example, an older box) I use
next: cat ~/.ssh/id_dsa.pub | ssh user@remotebox "cat >>
~/.ssh/authorized_keys"
Testing:
$ ssh user@remotebox
ssh-copy-id comes with openssh client package.
If that does not help I'd suggest you to check the contents of
~/.ssh/authorized_keys on remobe box if it contains some older keys
for that user.
If that still won't help I suggest you check the permissions of ~/ssh
directories on both the client and the server sides. Certain
files/directories should not have access to world, and definitely no
write access to world. You can run next command both on the client and
the remote box sides and show the output to us:
$ find ~/.ssh -ls
Cheers,
VL
- Follow-Ups:
- Re: passwordless login with same user id across box
- From: Dilip M
- Re: passwordless login with same user id across box
- References:
- passwordless login with same user id across box
- From: Dilip M
- passwordless login with same user id across box
- Prev by Date: passwordless login with same user id across box
- Next by Date: Re: passwordless login with same user id across box
- Previous by thread: passwordless login with same user id across box
- Next by thread: Re: passwordless login with same user id across box
- Index(es):
Relevant Pages
|