How to prevent being prompted for password for local account

5 posts / 0 new
Last post
nowhere86
Offline
Last seen: 5 years 9 months ago
Joined: 20.03.2014 - 13:39
How to prevent being prompted for password for local account

I activated a user 'test1' with CopSSH. This user is a local account on windows 2008. I'm able to transfer files from Linux to windows but get prompted for the password for test1. Don't see how public/private keys would be useable. How can I avoid the prompt so I can run this as a batch script?

Script from linux. (The private key doesn't make any difference)

rsync -avz -e "ssh -p 22 -i /home/test1/.ssh/rsync-only " /home/test1/backup/dummy_file.txt  "tester1@usctapd1234:/cygdrive/d/output"

 

 

itefix
Offline
Last seen: 1 hour 6 min ago
Joined: 01.05.2008 - 21:33
You try to rsync from your

You try to rsync from your Linux to Copssh server by using internal ssh transport. This scenario requires an rsync daemon on the fly fired up at Copssh side. The problem is Copssh has no rsync out of the box.  See our FAQ for a possible solution - https://www.itefix.no/i2/content/how-can-i-secure-connections-between-li...

NB! This requires an cwRsyncServer installed together with Copssh.

nowhere86
Offline
Last seen: 5 years 9 months ago
Joined: 20.03.2014 - 13:39
1. I'm able to copy 1 file

1. I'm able to copy 1 file from Linux to Windows 2008, although I get the error messages below.

2014/03/24 10:21:33 [5468] 127.0.0.1 is not a known address for "USCTAPD00960.mycomp.com": spoofed address?

2014/03/24 10:21:33 [5468] connect from UNKNOWN (127.0.0.1)

2014/03/24 10:21:33 [5468] rsync to backup/ from unknown (127.0.0.1)

2014/03/24 10:21:33 [5468] receiving file list

2014/03/24 10:21:34 [5468] sent 35 bytes received 53 bytes total size 18

2. Doesn't seem to matter whether I specify the private key or not - always
copies over the file anyway.

My rsyncd.conf:

use chroot = yes
strict modes = false
hosts allow = *
log file = rsyncd.log

[backup]
path = /cygdrive/c/backup/
read only = false
transfer logging = yes

Command line used: 
rsync -vrt /home/test/backup/from_0932.txt rsync://test@localhost:$localport/$rsyncmodule

 

itefix
Offline
Last seen: 1 hour 6 min ago
Joined: 01.05.2008 - 21:33
I can't see any error

I can't see any error messages, just warnings.

nowhere86
Offline
Last seen: 5 years 9 months ago
Joined: 20.03.2014 - 13:39
Was hoping to replace rsync

Was hoping to replace rsync commands with variables but doesn't seem to be working.

For example, was hoping to replace "--include '*.txt' --exclude '* " part of the command with a variable like $1. A python script would call a shell script passing $1. Is this possible at all?

From shell script:

rsync -vrt /home/test/backup/ --include '*.txt' --exclude '*'rsync://test@localhost:$localport/$rsyncmodule  

to:

rsync -vrt /home/test/backup/  $1'  rsync://test@localhost:$localport/$rsyncmodule