Trouble on setting the permissions and/or timestamp via command line

Advertisement

John Liu
Guest

Trouble on setting the permissions and/or timestamp via command line

I have a client with a SFTP server.

Here is the command line:
winscp.exe /console /script=test.txt /log=log.txt

Here is the script:

option transfer binary
open sftp://Username:PASSWORD@XXX:22/ -hostkey="xxx"
 
synchronize remote -delete -resumesupport=off -nopermissions -nopreservetime C:\CD \CD
synchronize remote -delete -resumesupport=off -nopermissions -nopreservetime C:\DQ \DQ
synchronize remote -delete -resumesupport=off -nopermissions -nopreservetime C:\IMP \IMP
 
exit

After running the script I get following in console:
transfer        binary    
Searching for host...
Connecting to host...
Authenticating...
Using username "Username".
Authenticating with pre-entered password.
Authenticated.
Starting the session...
Session started.
Active session: [1] Username@ip xxx
Comparing...
Local 'C:\CD' => Remote '\CD'
Synchronizing...
Local 'C:\CD' => Remote '\CD'
C:\CD\xxx.pdf |         736 KB |   97.4 KB/s | binary | 100%
Upload of file 'xxx.pdf' was successful, but error occurred while setting the permissions and/or timestamp.
If the problem persists, turn off setting permissions or preserving timestamp. Alternatively you can turn on 'Ignore permission errors' option.
The server does not support the operation.
Error code: 8
Error message from server:
(A)bort, (R)etry, (S)kip, Ski(p) all: Abort
Using WinSCP 5.11.2 (build 7781) on Windows 2012 R2.

Reply with quote

Advertisement

John Liu
Guest

New issues: turning off 'Optimize connection buffer size'

Thanks Martin for your quick feedback.
The issue on setting the permissions and/or timestamp via command line is fixed.
However, I have another issue:

Host is not communicating for more than 15 seconds.
Still waiting...
Note: If the problem repeats, try turning off 'Optimize connection buffer size'.
Warning: Aborting this operation will close connection!
(A)bort (60 s): Abort

Actually, I have set the script below:

put -resumesupport=off -nopermissions -nopreservetime  xxxxx\*.pdf
synchronize remote -criteria=size -resumesupport=off -nopermissions -nopreservetime xxxx\IMP

But I still have this issue.
Please kindly support how to fix this issue.

Reply with quote

Advertisement

You can post new topics in this forum