Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 04-24-2008, 05:24 AM   #1
LQ Newbie
Registered: Apr 2008
Posts: 16

Rep: Reputation: 0
copy folders between machines without password

i want to copy folder from one machine to other machines without it asking for password.
I dont want to set DSA keys since this would require to set key for each machine where i want to copy folder.
i went through man scp , it says that we can disable password by '-B' option but when i try it i get following error:
"Permission denied (publickey,gssapi-with-mic,password).
lost connection
have tried 'rsync' along with rsyncd.conf at remote machine but it still asks for password.

wat all is to be added in this conf file to disable password?? or any other command to disable password in any of these commands?? or any other way out?? plz suggest..
Old 04-24-2008, 07:36 AM   #2
Senior Member
Registered: Oct 2006
Distribution: Slackware 12 Kernel 2.6.24 - probably upgraded by now
Posts: 1,054

Rep: Reputation: 46
your best bet is to set up a key pair for each machine. its not that hard, it is very secure and safe.

Even if you -B , you will still have to type the password atleast once in the session iirc.

A simpler method could be to use sshfs , mount the remote dir and then just use cp/mv ... thats what I do many a times.

Other than that ... remember that in scp you can give multiple input files

scp file1 user@remote:
scp file2 user@remote:

can be replaced by
scp file1 file2 user@remote:

extend to any number of localfiles.
Old 04-24-2008, 08:07 AM   #3
Senior Member
Registered: Dec 2005
Location: Campinas/SP - Brazil
Distribution: SuSE, RHEL, Fedora, Ubuntu
Posts: 1,402
Blog Entries: 1

Rep: Reputation: 64
using rsync, you can set teh password in an environmental variable before you call rsync. something like that:
env RSYNC_PASSWORD=yourrsyncpasswdhere rsync -az --delete source_dir rsyncusr@remote::area

export RSYNC_PASSWORD=yourrsyncpasswdhere

# several rsync below
rsync -az --delete source_dir_1 rsyncusr@remote::area1
rsync -az --delete source_dir_2 rsyncusr@remote::area2
rsync -az --delete source_dir_3 rsyncusr@remote::area3
but, you must hear duryodhan: "its not that hard, it is very secure and safe."

have a second thought, please.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to copy folder between machines deepika5 Linux - Networking 23 09-03-2010 12:30 PM
how to copy folder between machines deepika5 Linux - Newbie 5 04-17-2008 01:34 PM
Share folders with Windows machines over network furcatus Linux - Networking 2 12-08-2005 11:08 AM
Copy Files across two machines. abhijeetudas Linux - Security 6 04-25-2005 03:50 AM
Moving Mozilla mail folders between machines rharvey@cox Linux - Software 6 02-13-2004 09:56 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:01 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration