Linux Forums - Linux Help,Advice & support community:LinuxSolved.com

Network Troublshooting => General Networking Support in Linux => Topic started by: chuikingman on August 19, 2009, 12:10:51 PM

Title: sftp/scp without password
Post by: chuikingman on August 19, 2009, 12:10:51 PM
Hi,
   I want to use sftp/scp without password in redhat linux.How can I do that ??I plan to to use sftp/scp in script and execute by cronjob ???any sample or example script ???
How can I test sftp/scp in the same user account ,. in the same linux server ????

thank
Title: Re: sftp/scp without password
Post by: pedro on September 02, 2009, 03:03:52 PM
Simple!
1. In the client type "ssh-keygen -t rsa". This generates a couple of files, you're interested in /home/username1/.ssh/id_rsa.pub.
2. Append the .pub file to the remote file /home/username2/.ssh/authorized_keys
3. That's it!
(username1 is the user name in the client, and username2 is the user name on the server)

Check for more detailed instructions:
http://www.linuxhorizon.ro/ssh-wo-passw.html

Cheers!

Pedro.