In the menu of a target you check all the backups stored there in one pass. And you clean away leftovers that an aborted job left behind at the target.
Opening the menu of the target
Open the Targets page and click More … in the row of the target.
- Test connection
- Check the backups at this target appears only if backups are stored at the target.
- Clean up leftovers at this target appears for target types that can list their files.
- Find backups at this target
- Edit
- Remove
Checking and cleaning up run as a job. Only one job runs at the same time; otherwise the page reports A job is already running.
Checking the backups at a target
Step 1: Start the check
In the menu, click Check the backups at this target. The plugin checks every backup at this target, the newest first.
Step 2: Follow the progress
- The progress: Checking backup, then the backup the check is currently working on (Backup … of …), the amount checked and the remaining time.
- Abort check stops the check at the next step.
At the beginning, instead of the time, calculating the remaining time … appears. A local folder is read by the plugin in place. From a remote target it fetches one part after another into its work folder, checks it and deletes it there again.
Step 3: Read the result
| Message | Meaning |
|---|---|
|
green All … backups at “…” checked: readable and complete. |
Everything is fine. |
|
red Check at “…”: … of … backups damaged or incomplete; the backup list marks them with a red cross. |
The log names the affected parts. For restoring, take a backup without a red cross. |
|
yellow Check at “…”: the target did not answer. |
At least one backup could not be checked. So it does not count as damaged. Test the connection and start the check once more. |
|
yellow Check aborted. |
You aborted the check. |
|
red Check failed. |
The check itself failed. Look in the log. |
If the target did not answer, the message looks like this:
- The result: the target did not answer. Below it are the cause and the original message from cURL.
- Log opens the log of the check.
Yellow and red messages lead with Log to the log of the check. On the Backup page, a mark then appears in front of the date of every checked backup: a green tick or a red cross. The tooltip at the mark names the date of the last check.
What is checked
The check reads a backup the way a restore would read it, and writes nothing back:
- Every file of the backup is stored at the target and has its size.
- The info file of the backup is valid.
- Every part has the size and the checksum stated in the info file.
- Every block can be read and unpacked, and the number of entries is correct. The database is included.
What a damaged backup means
If the check finds damaged or incomplete backups, the message is red:
- The result: how many backups at this target are damaged or incomplete.
- Log opens the log of the check. It names the affected parts.
If a backup fails at this target, it no longer counts there for Max. backups. The plugin never deletes it automatically: it stays until you delete it by hand.
Cleaning up leftovers at a target
What a leftover is
A job that ends midway, for example at a limit of the server, can leave behind a folder at the target that never becomes a backup. A leftover is a folder with a job name
- that has no info file,
- that does not belong to the running job
- and that the list of backups at this target does not include.
An unfinished upload also counts as a leftover. What the list of backups knows, the cleanup never touches. A folder with an info file that the list does not know is not a leftover but a backup: it stays. You bring it into the list with Find backups at this target.
Step 1: Start the cleanup
In the menu, click Clean up leftovers at this target. The progress display appears below the status tile.
- The progress: Cleaning up leftovers, then how many entries are done, the size and the remaining time.
- Abort backup stops the cleanup at the next step.
Step 2: Read the result
| Message | Meaning |
|---|---|
|
green No leftovers at “…”. |
There was nothing at the target that had to go. |
|
green Leftovers at “…” cleaned up: … folders, …. |
The message names the number of removed folders and the space that was freed. |
|
yellow Cleanup at “…”: the target did not answer. |
The plugin could not search for leftovers at the target. Test the connection and start again. The same message appears on a fingerprint conflict: The website has moved or is a copy. |
|
red Cleanup at “…”: … files could not be removed. See the log. |
Log in the message leads to the details. After an abort, the same message appears in yellow. |
If the plugin removed leftovers, the message looks like this:
- The result: how many folders with leftovers the plugin removed and how much space was freed by that.
The cleanup also runs on its own
After every good backup, the plugin cleans up at the targets at which this backup arrived. The same run removes old files from the plugin’s work folder on the web server: everything that has not been touched for an hour and does not belong to the running job.
Good to know
- Nothing checks backups on a schedule. The plugin already verifies every part while writing it; the check is there for when in doubt.
- You check a single backup on the Backup page: Check a backup.
- At an S3 target, an upload that was never finished keeps taking space at the service. The cleanup aborts such uploads, as far as the service lists them.
See also
- The “Targets” page
- Progress, messages and log
- Read the log
- Find backups again after a total loss
- Manage targets with WP-CLI
On the command line
WP-CLI not set up yet? How to install WP-CLI.
Both tasks also work with WP-CLI. The check prints one line per backup with the result. With --background, the command only starts the job; the website then drives it on by itself.
# Check the backups at a target wp cloneworx-backup target check sftp-1 # Only show which leftovers the cleanup would remove wp cloneworx-backup target cleanup sftp-1 --dry-run # Clean up leftovers at a target wp cloneworx-backup target cleanup sftp-1