Manage Windows Backups

To manage the Microsoft Windows Backups you can use a command line tool.

Open a command prompt as administrator

Show the existing backup versions

Wbadmin get versions

Clean up the backup disk

To keep a number of latest backups and delete the rest

Wbadmin delete backup -keepversions:NUMBER_OF_BACKUPS_TO_KEEP

To keep the latest backup only

Wbadmin delete backup -keepversions:1

To delete all existing backups

Wbadmin delete backup -keepversions:0

 

Create a backup of a Microsoft SQL Server database to a location outside of the database server

The Microsoft SQL Server Management Studio 2008 user interface only allows you to create a backup of a database to one of the local drives of the database server.

To create a backup of a Microsoft SQL Server database to a location outside of the database server execute the following SQL script:


BACKUP DATABASE MyDatabase TO
DISK = N'\\MyNas\MyDatabase.bak'
WITH NOFORMAT, NOINIT, NAME = N'MyDatabase Database Backup', NOSKIP, STATS = 10
GO

Change the bold values to match your environment.