Removing Sharepoint 2013 Backups

Sharepoint 2013 backups leave a lot to be desired. But here’s something new I just came across. Sharepoint 2013 has no built in way to setup a backup retention period or any method to remove old backups to free up space.

So whether you use a backup script running as a scheduled task or you take manual backups from the Central Admin GUI, MS gives you no way to remove the old data.

So here’s how I do it:

1) You have to go to the folder used as the backup target and locate the spbrtoc.xml file. Make a backup of that file just in case.

2) Edit spbrtoc.xml. Note that each SPHistoryObject references a backup date, folder, and whether it was Full or Differential.

3) Delete the SPHistoryObjects entries in the spbrtoc.xml and the respective folders that correspond to the backups you wish to remove. I tend to remove the oldest backups and keep 2 weeks worth of backups.

4) Check Central Administration -> Backup and Restore -> View Backup and Restore History. The older backups should now be gone.

Have a better way of doing this? Let me know about it. Thanks.