Do I need to save this? Will this be useful later? It can be hard to determine how much data will be needed as time goes on; and considering the rate at which new CAD data is added to the SOLIDWORKS PDM vault, this quantity is likely to increase. To reduce the stress on server hard drives, there are a few techniques to managing PDM archive.
Disclaimer: Before taking any steps to relocate, remove, or compress data, please ensure that all files have been checked in by the users, and that backups have been taken of both the database and archives. In the event of a relocation, have all users log off or go into Offline Mode before attempting the move.
Over the course of this blog series, I’m going to cover a few methods:
- Cleanup – Permanently removing deleted files
- Distribution – Relocating a partial or full archive to a different disk
- Compression – Reducing the size of older versions on the archive
- Cold Storage Schemas – Automatically deleting older versions
Vault cleanup is a task that is performed on a regular basis without any action however, there are some additional actions to speed up the process. The automatic cleaner service will remove destroyed and orphaned files from the archive. When files are destroyed by either the user or the recycle bin, only the database records are purged. Later, the automatic cleaner will scan the archive and remove the files that no longer have records.
Cleaner Service Schedule
By default, the vault cleaner service runs at 3:00 AM but can be adjusted to run on your specific schedule. To override the default time, create a new string registry value called CleanerSchedule at:
HKEY_LOCAL_MACHINE\SOFTWARE\SolidWorks\Applications\PDMWorks Enterprise\ArchiveServer\Vaults\[Vault Name
The value of the string can be the word “off” to disable the cleanup operation in the specified vault, or it can be constructed of three sections – Minute Hour Weekday. It is built as such:
- Minute – 0 through 59 (0 minutes past the hour)
- Hour – 0 through 23 (0 is midnight)
- Weekday – 1 through 7 (1 is Monday)
The sections can contain a single number (1), a range (1-7), or a list of numbers (0,15,30,45). Sections are delimited by a single space. A wildcard can be used by placing an asterisk (*) in a section.
Here is an example of how these schedules would look:
- 0 0 * – Every midnight
- 0 0 1-5 – Every weekday at midnight
- 0 * * – Every hour, every day
- 0,15,30,45 * 1-5 Every 15 minutes, every weekday
If changes are made to the cleaner values, restart the Archive Server Service to put it into effect.
How to destroy deleted files in SOLIDWORKS
Over time, deleted files will build up in the background, taking up space in the database and archive. Periodically (depending on how often disk space is an issue and how many deleted files are created over time) it’s smart to destroy previously deleted files.
Access the list of deleted files by right-clicking the white space of a folder and selecting Properties.
The properties dialog lists several tabs; select the Deleted Items tab. Here is a list of files that have been deleted as well as who deleted them and when as well as the size and location.
This action can be repeated in any folder; however, it may be best suited from the root of the vault. From here, the option to “include items in sub-folders” can be selected to see all files deleted through the entire vault.
If all the permissions to destroy have been granted, any file can be right-clicked to get the option to destroy or restore. Once this is selected, there is a final prompt before the file is permanently removed from the database. (Note: The actual files will be removed once the cleaner service runs – results will be not seen until then.)
Check out part two to learn how to manage your SOLIDWORKS PDM archive with distribution techniques.