⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 syncupload.wrk

📁 同步软件源码,作者 Jeroen C. Kessels Internet Engineer
💻 WRK
字号:
# SyncUpload
#
# Maintain an exact copy (backup) of a directory (and it's subdirectories)
# onto another machine (slave) via the network. Traffic is one-way only,
# files are only sent from the master to the slave. The program uses
# passwords (challenge/response) to protect the access and an MD5 hash to
# make sure the files on the slave are exactly the same as on the master.
#
# The slave must be running the SyncServer program. Network traffic uses
# port 9577, which must be open in firewalls and such.
#
# This configuration file on the master defines the directories and files
# that will be synchronised. A configuration file on the slave defines the
# access that the slave will permit. The SyncUpload program is started on
# the master and will contact the slave, compare the files, send new or
# changed files, and issue delete commands for old files. The result is
# that the slave will contain an exact copy of the files on the master.
# Even the date/time will be exactly the same.
#
#
#
# USAGE
#
#     syncupload [-c] [-d] [-h] filename
#
#       -c           Do not copy and/or delete, just compare the files.
#       -d           Debug mode, show all network traffic.
#       -h           Show this usage text.
#       filename(s)  Process workfile(s) "filename.WRK".
#
# You may cancel the program at any time, for example by CTRL-C, Break, or
# by closing the window. You can restart whenever you like.
#
# Tip: you can save the output messages in a logfile like this:
#     syncserver example.wrk > example.log
#
#
#
# WORKFILE
#
#     #         Comment. Lines that begin with this character (and empty
#               lines) will be ignored.
#     include LocalMask [RemoteMask]
#               Include all the files that match the LocalMask. The mask
#               may contain wildcards such as '*' and '?'. If a RemoteMask
#               is specified then the files will be stored on the slave
#               in that location, replacing the wildcards by the
#               corresponding values from the LocalMask. If no RemoteMask
#               is specified then the files will be stored on the slave
#               in the same location as on the master. You may specify
#               more than one Include line.
#     exclude Mask
#               Exclude all the files that match the mask. The mask may
#               contain wildcards such as '*' and '?'. You may specify
#               more than one Exclude line.
#     slave IPaddress Password
#               The IPaddress of the slave and the Password to gain access.
#               The slave must be running the SyncServer, and the Password
#               must be configured in it's configuration file. You may
#               specify more than one Slave line, which will be processed
#               in sequence (all files are synchronised with the slave on
#               the first line, then the slave on the second line, etc.).
#
# The name of a file (path) is translated with the RemoteMask before it is
# sent. The slave will grant access if the translated path exactly matches a
# line in it's configuration file. Translation takes the part in the LocalMask
# before the wildcard and replaces it with the corresponding part in the
# RemoteMask. For example:
#     If
#       LocalMask  = c:/Inetpub/wwwroot/www.kessels.com/*
#     and
#       RemoteMask = d:/ServerBackup/www.kessels.com/*
#     then file
#       c:/Inetpub/wwwroot/www.kessels.com/index.html
#     will be stored on the slave as
#       d:/ServerBackup/www.kessels.com/index.html
#     The configuration file on the slave must contain a line to grant access
#     to:
#       PathMask   = d:/ServerBackup/www.kessels.com/*
#
# If a string contains a space then it must be enclosed in double-quotes.
#     WRONG:    c:/Program Files/whatever/*
#     RIGHT:    "c:/Program Files/whatever/*"
#
# You must create a separate workfile for every task you wish to perform.
# For example, if you wish to synchronize a path to slave A, and another
# path to slave B, then you must make two separate workfiles.
#
#
#
# WARNING
#
#     Make sure you have set the correct paths. The program will delete
#     all files in the path on the slave that are not present on the master!
#
#
#
# KNOWN PROBLEMS
#
# - The program can only synchronise files to which it has read access.
#   Make sure that the userid that starts the program has read access to
#   all the files, for example a userid with Administrator permissions.
# - The program does not copy permissions. The files on the slave will
#   have the default permissions (usually the permission of their parent
#   directory).
# - If a file changes after the program is started and before it is sent
#   to the slave, then it will be skipped. This can mean for example that
#   a busy database is not copied.
# - The program has not been tested with special Windows files such as
#   temporary files, sparse files, and reparse points.
# - The communication between slave and master is not encrypted. It may
#   therefore theoretically be listened to by a hacker. The password
#   is encrypted (using an MD5 challenge/response protocol), so hackers
#   cannot see it and not start their own session. Also, traffic is in one
#   direction only, the master does not receive files and therefore
#   cannot be corrupted.
#
#
#
# Copyright:   Jeroen C. Kessels
# Date:        19 august 2005
# Version:     4



include     c:/Inetpub/wwwroot/www.kessels.com/* d:/ServerBackup/www.kessels.com/*
exclude     c:/*/logs/*
exclude     c:/*.log
slave       server5.kessels.com fhdjsfjsfjdkhsfkdgs

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -