synchronize remote all files allways

Advertisement

untouchable
Joined:
Posts:
2
Location:
Switzerland

synchronize remote all files allways

Hi there
Im searching a script that synchronizes my remote files no matter what timestamp, or anything. All files should be synchronized from local to remote no matter if they allready exist or not (create new files or overwrite existing files).

I've tried with that script:

synchronize remote -criteria=none -filemask="PDS_STRUB*.|*/" "\\STRUBAD01\AlteDaten\Produktedokumentation\Datenblätter\deutsch\01 Motorenoele" "/share/CACHEDEV1_DATA/STRUB-Data/Deutsch/01 Motorenoele/01 Datenblätter"

but in log there is a entry "exluded from synchronization". How do I have to do this?
  • WinSCP.zip (231.78 KB, Private file)
Description: Log File

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: synchronize remote all files allways

What you want is not a synchronization. It's a dumb upload.

So use put command:

put -filemask="PDS_STRUB*.|*/" "\\STRUBAD01\AlteDaten\Produktedokumentation\Datenblätter\deutsch\01 Motorenoele\*" "/share/CACHEDEV1_DATA/STRUB-Data/Deutsch/01 Motorenoele/01 Datenblätter/"

https://winscp.net/eng/docs/scriptcommand_put

Reply with quote

untouchable
Joined:
Posts:
2
Location:
Switzerland

Re: synchronize remote all files allways

martin wrote:

What you want is not a synchronization. It's a dumb upload.

So use put command:

put -filemask="PDS_STRUB*.|*/" "\\STRUBAD01\AlteDaten\Produktedokumentation\Datenblätter\deutsch\01 Motorenoele\*" "/share/CACHEDEV1_DATA/STRUB-Data/Deutsch/01 Motorenoele/01 Datenblätter/"

https://winscp.net/eng/docs/scriptcommand_put

Hi, tried that but still not working. This is the script i'm using.
option batch on
option confirm off
open sftp://xxxx:xxxxxxx/ -hostkey="ssh-rsa 2048 xxxxxxxxxxxxxxxxxxxx
# Synchronisation der Datenblätter
put -filemask="PDS_STRUB*.|*/" "\\STRUBAD01\AlteDaten\Produktedokumentation\Datenblätter\deutsch\01 Motorenoele\*" "/share/CACHEDEV1_DATA/STRUB-Data/Deutsch/01 Motorenoele/01 Datenblätter/"

Still got excluded from Transfer in log. Could it be a Problem because files allready exists?

thx
Andreas
  • WinSCP.zip (83.06 KB, Private file)
Description: Logfile

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: synchronize remote all files allways

All the files that got excluded were excluded rightly, as they do not match the file mask.

So you probably have the filemask wrong.

But I cannot know what files you actually want to transfer.

Maybe you wanted PDS_STRUB*.* instead of PDS_STRUB*.?

Reply with quote

Advertisement

You can post new topics in this forum