Don’t check-in huge files
WIP repository is not designed to store large files, like QVD or videos. It can do it but the size of the database will quickly become huge, and this is not the purpose of a version control system, so use a backup system for this purpose.
Delete unnecessary files and version
If you delete a file in WIP, it is put in the recycle bin. If you want to recover space, you need to empty recycle bin or physically delete files pressing the Recycle Bin button
Purge Database
You can delete old versions and keep only the X latest ones keeping the versions that have been published to production. The option is available in the WIP Setup under the Database tab, set the #Version to keep and #Month to Keep and press the Purge database button.
WIP Setup will physically delete the not published versions matching the criteria.
Recovering SQL Server Database Space
Note: if you use MS SQL Server Express database, the data size is limited to 10 GB, you should be careful not to exceed this value otherwise the program will stop working.
Deleting versions or purge database will have no effect on the database file size. In order to recover space please consult the following link.
https://www.sqlshack.com/sql-server-transaction-log-backup-truncate-and-shrink-operations/
In short you need to set your database “Recovery Model” to Simple and auto shrink your database
If you want to keep the “Recovery Model” to Full you need to make a full backup, then a log backup then shrink the database and then the log
BACKUP DATABASE [WIP_MT_Release_hotfix] TO DISK = N'C:\Program Files\Microsoft SQL Server\MSSQL14.MSSQLSERVER\MSSQL\Backup\WIP_MT_Release_hotfix.bak' WITH NOFORMAT, NOINIT, NAME = N'WIP_MT_Release_hotfix', SKIP, NOREWIND, NOUNLOAD, COMPRESSION, STATS = 10 GO BACKUP LOG [WIP_MT_Release_hotfix] TO DISK = N'C:\Program Files\Microsoft SQL Server\MSSQL14.MSSQLSERVER\MSSQL\Backup\WIP_MT_Release_hotfix.log_bak' WITH NOFORMAT, NOINIT, NAME = N'WIP_MT_Release_hotfix_log', SKIP, NOREWIND, NOUNLOAD, COMPRESSION, STATS = 10 GO
Shrink the log after backup
Add Comment