PowerShell Logo Small


This is the built-in help made by Microsoft for the command 'Set-ADForestMode', in PowerShell version 5 - as retrieved from Windows version 'Microsoft Windows Server 2012 R2 Standard' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.


Sets the forest mode for an Active Directory forest.


Set-ADForestMode [-Identity] <ADForest> [-ForestMode] {UnknownForest | Windows2000Forest | Windows2003InterimForest | Windows2003Forest | Windows2008Forest |
Windows2008R2Forest | Windows2012Forest | Windows2012R2Forest} [-AuthType {Negotiate | Basic}] [-Credential <PSCredential>] [-PassThru] [-Server <String>] [-Confirm]
[-WhatIf] [<CommonParameters>]

Search powershellhelp.space


The Set-ADForestMode cmdlet sets the Forest mode for an Active Directory forest. You specify the forest mode by setting the ForestMode parameter.

The Identity parameter specifies the Active Directory forest to modify. You can identify a forest by its fully qualified domain name (FQDN), GUID, DNS host name, or NetBIOS
name. You can also specify the forest by passing a forest object through the pipeline. For example, you can use the Get-ADForest cmdlet to retrieve a forest object and then
pass the object through the pipeline to the Set-ADForestMode cmdlet.

Set-ADForestMode will prompt for confirmation by default.



Online Version: http://go.microsoft.com/fwlink/p/?linkid=291120




-------------------------- EXAMPLE 1 --------------------------

PS C:\>Set-ADForestMode -Identity fabrikam.com -ForestMode Windows2003Forest

This command sets the ForestMode to Windows2003Forest in the forest fabrikam.com.

-------------------------- EXAMPLE 2 --------------------------

PS C:\>$currentForest = Get-ADForest
PS C:\> Set-ADForestMode -Identity $currentForest -Server $currentForest.SchemaMaster -ForestMode Windows2008R2Forest

This example sets the forest mode of the current logged on user's forest. The set operation targets the Schema Master FSMO to apply the update.