This article describes how to initiate on-demand scans through a trigger file update.
Optional: Create real-time jobs for subfolders of main trigger file job directory to process file changes in real-time mode.
Note: Trigger File Selection for v7.2 and above is part of the Scan Limitations screen (Included in the Enhanced Package).
The Profile will have the following job(s):
- Trigger File Replication job - Job in charge of trigger file monitoring and directory scanning to update target directory.
- (OPTIONAL) Enhanced real-time scan job - Job in charge of enhanced real-time monitoring of subfolders of the main folder scan job.
Trigger File Replication Job
This job will be in charge of trigger file monitoring only. Its source will be the folder where the trigger file is located. The trigger file may be located in the root folder of the scan folder or simply in a separate outside folder.
For this tutorial, we assume the trigger file will be placed into the source root folder.
- Add a new job by clicking on Job from the top toolbar and choosing Add->Job with Defaults.
- Double-click the job name and rename this job to Trigger File Replication Initiation Job.
- Select Folder Selection from the left menu tree and identify your Source and Target folder. This is the folder where the trigger file is located.
- Make sure the Include Subfolder option is checked.
- Select Reporting from the left menu tree. Rename the log file from PeerSync.log to %JobName%.log. This will create a unique log file with the job name as its file name.
- Select File Options from the left menu tree. Select Add and Update, and optionally Replicate.
- Select Automation from the left menu tree. Make sure the Scan Job once at start is enabled.
- From the Automation screen, select Scan Job every “1” minute. Alternatively, you can opt for a fraction of 1 minute (e.g., 0.1) to monitor the trigger file at intervals shorter than 1 minute. This is not recommended for regular job scans.
- Select Scan Limitations from the left menu tree. Enter the full path of your source folder and the name of the trigger file (publishdone.txt), do the same for the target trigger file.
- For v7.1: Go to Operation Mode and select Scan at Start.
- If you have any Enhanced Real-Time Scans for subfolders of this job’s directory, make sure you exclude the real-time folder within the Exceptions screen -> Exclude Folders field by simply identifying the folder name (e.g., /foldername/)
Note: If using v7.1, make sure the Automation Options settings under Global Settings - Operation Mode includes all the automation modes selected within the profile based on the Automation modes for the individual jobs.
Pre/Post Processes Set UPDATETRIGGERFILE
To create/touch a specified trigger file with the purpose of enabling further action.
(For example, to kick off the next level synchronization, such as in a multi-tier synchronization process)
This argument is included in the Pre/Post Process window.
Use the following format to set up the UPDATETRIGGERFILE in the BEFORE or AFTER field of the Pre/Post Process section.
UPDATETRIGGERFILE “file path”
The %TARGETPATH% variable takes the full target directory path.
Enhanced Real-Time Scan Job
This job will be in charge of running one of the main folder scan subfolders in an Enhanced Real-Time Mode that will process file events as they are occurring on the source local folder.