Tuesday, March 26, 2013

SharePoint 2013 Backup and Recovery cmdlets

Whatever is the theme of your business, your full business depends on your data & if you lost your data, it can interrupt your whole business continuity. So if you don't want to OUT OF the MARKET then you should plan for proactive backup and recovery policies for your data. There are so many reasons of data corruption and not all are easily fixed. Here is the survey of data loss reasons: 

















But one of the famous & working approach to keep your data safe is 'BACKUP'. SharePoint 2013 is also introduced Backup and recovery cmdlets which will help you to backup & recover your corrupt SharePoint Server. You can use this SharePoint 2013 functionality to backup & restore various SharePoint items such as Farm, Site collection, Configuration database, Services, document etc. 


Let’s have a look of all cmdlets one by one: 



Backup-SPConfigurationDatabase: 



This cmdlet used to perform either configuration-only backup of the current farm or a configuration-only backup of a separate configuration database which is not attached to the current farm. If you wish to perform a configuration-only backup of the current farm. Here is command: 



Backup-SPConfigurationDatabase -Directory <String> [-AssignmentCollection <SPAssignmentCollection>] [-DatabaseCredentials <PSCredential>] [-DatabaseName <String>] [-DatabaseServer <String>] [-Item <String>]



AND



Backup-SPConfigurationDatabase -ShowTree <SwitchParameter> [-AssignmentCollection <SPAssignmentCollection>] [-DatabaseCredentials <PSCredential>] [-DatabaseName <String>] [-DatabaseServer <String>] [-Item <String>]



Backup-SPFarm: 



This cmdlet used to create entire farm backup or individual components within the farm. Here is command: 



Backup-SPFarm -BackupMethod <String> -Directory <String> [-AssignmentCollection <SPAssignmentCollection>] [-BackupThreads <Int32>] [-ConfigurationOnly <SwitchParameter>] [-Confirm [<SwitchParameter>]] [-Force <SwitchParameter>] [-Item <String>] [-Percentage <Int32>] [-WhatIf [<SwitchParameter>]]



AND



Backup-SPFarm -ShowTree <SwitchParameter> [-AssignmentCollection <SPAssignmentCollection>] [-ConfigurationOnly <SwitchParameter>] [-Confirm [<SwitchParameter>]] [-Item <String>] [-WhatIf [<SwitchParameter>]]



Restore-SPFarm: 



This cmdlet used to restore one or more items (individual database, Web application, or the entire farm) from the backup. Here is command: 



Restore-SPFarm -Directory <String> -RestoreMethod <String> [-AssignmentCollection <SPAssignmentCollection>] [-BackupId <Guid>] [-ConfigurationOnly <SwitchParameter>] [-Confirm [<SwitchParameter>]] [-FarmCredentials <PSCredential>] [-Force <SwitchParameter>] [-Item <String>] [-NewDatabaseServer <String>] [-Percentage <Int32>] [-RestoreThreads <Int32>] [-WhatIf [<SwitchParameter>]]



AND 



Restore-SPFarm -Directory <String> -ShowTree <SwitchParameter> [-AssignmentCollection <SPAssignmentCollection>] [-BackupId <Guid>] [-ConfigurationOnly <SwitchParameter>] [-Confirm [<SwitchParameter>]] [-Item <String>] [-WhatIf [<SwitchParameter>]]



Backup-SPSite: 



This cmdlet used to perform site collection backup when the 'Identity' parameter is used. Here is command: 



Backup-SPSite [-Identity] <SPSitePipeBind> -Path <String> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-Force <SwitchParameter>] [-NoSiteLock <SwitchParameter>] [-UseSqlSnapshot <SwitchParameter>] [-WhatIf [<SwitchParameter>]]



Restore-SPSite: 



This cmdlet used to restore a site collection to a location specified by the 'Identity' parameter. Here is command: 



Restore-SPSite [-Identity] <String> -Path <String> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-ContentDatabase <SPContentDatabasePipeBind>] [-Force <SwitchParameter>] [-GradualDelete <SwitchParameter>] [-HostHeaderWebApplication <String>] [-PreserveSiteID <SwitchParameter>] [-WhatIf [<SwitchParameter>]]



Get-SPBackupHistory: 



This cmdlet used to track the history of backup and restore operations that have been completed. Here is command: 



Get-SPBackupHistory -Directory <String> [-AssignmentCollection <SPAssignmentCollection>] [-ShowBackup <SwitchParameter>] [-ShowRestore <SwitchParameter>]







If your Backup is Not Good Enough to perform Restoration then WHAT?


If your backup is not well structured then it will not help you to recover your data at any cost. In this case, you have one another solution to repair your corrupt SharePoint database that is SharePoint Server Recovery Tool. These software help users to repair corrupt SharePoint database in all corruption cases. 





A good backup is an excellent approach to prevent data loss & repair database in most of the data corruption cases. 

No comments:

Post a Comment