Most of us know that to restore the master database on SQL you need to get the instance started in single user mode however we usually forget the syntax so here it is:

  • Go to SQL Server Configuration Manager
  • Click on the SQL Server Services
  • Right Click the SQL Engine Service for the instance you need to start in single user mode
  • At the beginning of the Startup Parameters enter ‘-m;
  • Restart the instance

Once the instance is restarted you will need to use SQLCMD to communicate with the instance to do the restore, from a command prompt enter:sqlcmd.exe -S computername\instancenameRESTORE DATABASE master FROM DISK = ‘pathtobackupfile\master.bak’ WITH REPLACE;
GOThe instance will now shutdown.Go back to SQL Server Configuration Manager and remove the -m; from the startup parameters and start the instance.