Refer to the following tables for considerations for backup and restoration of system databases.
SQL server maintains a set of system level database which are essential for the operation of the server instance. Several of the system databases must be backed up after every significant update, they include:
This table summarizes all of the system databases.
|master||The database that records all of the system level information of a SQL server system.||Yes|| To back up any database, the instance of SQL server must be running.
Startup of an instance of SQL server requires that the master database is accessible and at least partly usable.
Back up the master database as often as necessary to protect the data sufficiently for your business needs.
Microsoft recommends a regular backup schedule, which you can supplement with manual backup after any substantial update.
|model||The template for all databases that are created on the instance of SQL server.||Yes|| Backup the model database only when necessary, for example, after customizing its database options.
Microsoft recommends that you create only full database backups of model, as required. Because model is small and rarely changes, backing up the log is unnecessary.
|msdb||The msdb database is used by SQL Server Agent for scheduling alerts and jobs, and for recording operators. It also contains history tables (e.g. backup / restore history table).||Yes||Back up the msdb whenever it is updated.|
|tempdb||A workspace for holding temporary or intermediate result sets. This database is recreated every time an instance of SQL server is started.||No||The tempdb system database cannot be backed up.|
|distribution|| The distribution database exists only if the server is configured as a replication distributor. |
It stores metadata and history data for all types of replication, and transactions for transactional replication.
|Yes||Replicated databases and their associated system databases should be backed up regularly.|
|Heading 1||Heading 2|
|master|| To restore any database, the instance of SQL server must be running. Startup of an instance of SQL server requires that the master database is accessible and at least partly usable.
Restore or rebuild the master database completely if master becomes unusable.
|model|| Restore the model database if:
* The master database has been rebuilt.
* The model database has been damaged, for example due to media failure.
* The model database has been modified, in this case, it is necessary to restore model from a backup when you rebuild master, because the Rebuild Master utility deletes and recreates model.
|msdb||Restore the msdb database if the master database has been rebuilt.|
|distribution||For restore strategies of distribution database, please refer to the following online document from Microsoft for more details: http://msdn.microsoft.com/enus/library/ms152560.aspx|
The following are some best practice and recommendation we strongly recommend you to follow before you start any MS SQL Server backup and restore.