⚠️ THIS SHOULD ONLY BE DONE BY QUALIFIED IT PERSONNEL
⚠️ This article applies to pVault only. For Sage Paperless, Click Here
In lieu of scheduling a full Paperless Application Server reboot, customers can also have the Paperless Services start and stop on a schedule using a batch file and the Windows Task Scheduler.
Use Notepad to create a simple batch file.
The following example stops each service and then restarts each service. The pings are used as a pause feature between steps and can be adjusted to whatever suits the customer's environment. In our example, the number after the -n in each line represents the number of seconds to wait before the next command is executed. There are other ways to handle the pause as well. This is just one example.
Important: Quotes must be included due to the spaces in the service names.
net stop "paperless polling service"
ping localhost -n 3 >NUL
net stop "paperless cloud synchronization"
ping localhost -n 3 >NUL
net stop "pvault application server"
ping localhost -n 10 >NUL
net start "pvault application server"
ping localhost -n 30 >NUL
net start "paperless cloud synchronization"
ping localhost -n 3 >NUL
net start "paperless polling service"
⚠️ Important: Quotes must be included due to the spaces in the service names.
In this case, the batch file is named StartStop.bat and is saved in a folder labeled C:\Scripts.In Windows, access Task Scheduler. This is where you schedule the batch file to run.
Click Create a Basic Task.
The Create Basic Task Wizard window similar to the following displaysIn the Name field, enter the Task name.
Click Next.
In the Task Trigger wizard window, click to select how often the task should run. Weekly is usally enough, but some customers will opt for daily.
Click Next.
In the Weekly wizard window (window name reflects the frequency selected in the Task Trigger wizard window), specify the day/days and the time the task should run.
Click Next.
In the Action wizard window, click Start a program.
Click Next.
In the Start a Program wizard window, click Browse to select the batch file created earlier. The path will display in the Program/script text box.
Click Next.
In the Summary wizard window, click to select the Open the Properties dialog for this task when I click Finish checkbox.
Click Finish.
The Properties dialog box for the newly created Task displays with the General tab active.Make sure the selected user account has the proper security permissions to run tasks on the server.
A dedicated account is recommended for this with the associated password set to never expire.
Note: To select a different user account, click Change User or Group.Click to select: Run whether user is logged on or not
Click to select: Run with highest privileges
Click OK.
Click the Settings tab.
The dialog box similar to the following displays:Click to select the following options:
- Allow task to be run on demand
- Stop the task if it runs longer than
- 1 hour (from the dropdown)
- If the running task does not end when requested, force it to stopClick OK.
Note: A prompt may display requiring that Service Account Credentials be re-entered.
The new task should display as Ready in the Task Scheduler grid, similar to the following: