Automated Synchronisation of server files and local files

血红的双手。 提交于 2019-12-23 04:47:10

问题


Is there any application that does a automated update of the server file and local file? WinSCP does the local to server update and uni directional. Is there any bidirectional application?


回答1:


Winscp is bi direcional. I currently use this program to automate a directory of documents to 100+ computers. A simple batch file containing the commands found on this page:

http://winscp.net/eng/docs/scriptcommand_synchronize

Below,is the batch file I use to accomplish a sync from an ftp server to a local directory, deleting any changes on the local side.The batch file also saves a XML log of all transfers.

@echo off
cd %programfiles(x86)%\winscp\
start /b winscp.exe /log="C:\Sync\logs\!M-!D-!Y@!T.xml" /xmlgroups /command "open   ftp://username:password@ftp.foo.com" "synchronize local -delete -criteria=size     ""C:\Users\jdoe\Documents\Synced Docs"" / 

The parameter that you will want to play with is the "synchronize local -delete -criteria=size"

I have had this in place for about a year and it works great. Let me know if you have any questions.



来源:https://stackoverflow.com/questions/10005045/automated-synchronisation-of-server-files-and-local-files

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!