« Previous 1 2 3 Next »
Disaster recovery for Windows servers
Window Repairs
Restoring a Complete Server
To restore 2012 R2 Windows Server from a full backup, you do not have to rely on third-party software. If you install Windows Server Backup via the Server Manager and back up the complete server on an external drive, you can restore completely on the basis of this backup.
To use Windows Server Backup, you need to install it using Server Manager. Windows Server 2012 R2 offers a Windows Server Backup
feature. After the install, launch the backup from the Tools menu in Server Manager, by selecting Windows Server Backup
. Alternatively, you can search for wbadmin.msc
on the home screen.
The program will perform a complete block-based backup of the disk. Microsoft recommends backing up an external drive that is formatted automatically by the backup program so that all previously stored data is lost. To create a new job, select Action | Backup Schedule . For a custom backup, you can select which partitions to back up (Figure 3).
For scripts or core servers, the command-line tool wbadmin
manages your backups. The most important commands:
- Display information about the available backups:
wbadmin get versions
- Indicate the status of a current backup or restore:
wbadmin get status
- Restore the system state:
wbadmin start systemstaterecovery
- Start a full system backup that can be restored via the computer repair options on the installation DVD of Windows Server 2012 R2:
wbadmin start sysrecovery/systemstatebackup
- Start the backup immediately using
-quiet
to avoid the need to confirm entries:
wbadmin start backup -allCritical -backupTarget:<targetdisk> -quiet
- Display all assigned partitions that are included in the backup:
wbadmin start backup -include:<Partition1>:,...,<PartitionN>:-backupTarget:<targetdisk>: -quiet
The partitions are comma-separated without spaces.
Instead of using wbadmin
, you can manage your backup in PowerShell. The Get-Command-Module WindowsServerBackup
Cmdlet in Windows Server 2012 R2 shows you the matching Cmdlets.
After creating a full backup on the server, you can use it to restore the complete server if it fails to boot. To do this, the media containing the backup must be connected to the server, and you must boot to Windows Server 2012 R2 DVD.
When the Installation Wizard comes up, select Next then Repair your computer to bring up the system restore features. To select the option to restore a system image backup, click on Troubleshoot then System Image Recovery (Figure 4).
Bare Metal Restore on New Hardware
Windows Server 2008 R2 and Windows Server 2012/2012 R2 let you restore a system backup on different hardware. In the wizard, you can select the backup image by date and time of the backup (Figure 5); then, be sure to select the Bare metal recovery option.
Use the Exclude disks button to select a disk that you will not be restoring, because, for example, it only contains data and no operating system files. Selecting Install drivers lets you integrate important drivers that are required for the recovery. In the options under Advanced , you can specify that the server should start automatically after the restore and verify the disk for defects.
Backing Up and Restoring Active Directory
Active Directory is backed up together with other important system components of a server. This backup, which can be carried out by the native Windows Backup program, also saves all the data required by Active Directory. For the backup, enable the options System state and System Reserved so that the data required for recovery of Active Directory is also backed up. You will also want to back up the bare metal data. To perform a restore, start the domain controller and, directly after starting, press the F8 key until the boot menu appears. Make sure the file containing the backup resides locally on the server, because it is needed for recovery.
In the Boot Options menu, select Directory Services Restore Mode , and Windows will then start. Log in to the application with the password for Active Directory restore mode. After you have logged in, you can complete the restore. You also can enable directory services restore mode via an RDP session or a command-line command on the local console.
If you want to boot a domain controller into the directory services restore mode, enter bcdedit /set safeboot dsrepair
. If the server is in directory services restore mode, you can enter bcdedit /deletevalue safeboot
to tell it to boot normally next time. This saves you from pressing the F8 key if you are not, for example, sitting directly in front of the console. The shutdown t 0 -r
command reboots the server in the configured mode. You must install the same version of the operating system as before the failure.
The approach of rejoining the domain with a domain controller, rather than restoring a backup, is often faster and cleaner. However, you should clean up the Active Directory metadata before rejoining a domain to ensure that no stale data exists in the Active Directory preventing you from promoting the domain controller.
« Previous 1 2 3 Next »
Buy this article as PDF
(incl. VAT)