Share via


Disable-CsAdForest

 

Topic Last Modified: 2012-04-25

Undoes the forest preparation tasks carried out by the Enable-CsAdForest cmdlet. This cmdlet is typically used only if you are uninstalling Microsoft Lync Server 2010.

Syntax

Disable-CsAdForest [-Confirm [<SwitchParameter>]] [-Force <SwitchParameter>] [-GlobalCatalog <Fqdn>] [-GlobalSettingsDomainController <Fqdn>] [-GroupDomain <Fqdn>] [-GroupDomainController <Fqdn>] [-Report <String>] [-RootDomainController <Fqdn>] [-WhatIf [<SwitchParameter>]]

Detailed Description

When you install Lync Server 2010, you make a number of forest-level changes to Active Directory Domain Services (AD DS). These changes (which can be carried out by using the Enable-CsAdForest cmdlet) include creating objects and display specifiers that are specific to Lync Server 2010, creating universal security groups needed to manage Lync Server 2010, and granting global settings object access administrative rights and permissions to these groups. If you later decide to uninstall Lync Server 2010 (or if you encounter issues during the setup process) you might need to roll back these forest-level changes. The Disable-CsAdForest cmdlet provides a way for you to undo all the forest-level modifications made by the Enable-CsAdForest cmdlet.

Note that running this cmdlet will not only disable the forest for Lync Server 2010 but also for any previous versions of the software as well (such as Microsoft Office Communications Server 2007 R2). For example, suppose you are using both Lync Server and Office Communications Server 2007 R2. If you run the Disable-CsAdForest cmdlet users will no longer be able to log on to either system.

The tasks carried out by Disable-CsAdForest are similar to the tasks carried out by the following Microsoft Office Communications Server 2007 R2 command:

Lcscmd.exe /forest /action:ForestUnprep

Who can run this cmdlet: You must be an enterprise administrator in order to run the Disable-CsAdForest cmdlet locally.

Parameters

Parameter Required Type Description

GroupDomain

Optional

String

Fully qualified domain name (FQDN) of the domain where the Lync Server 2010 universal groups were created (for example, -GroupDomain asia.litwareinc.com). If this parameter is not included, Disable-CsAdForest will look for the universal groups in the local domain.

GroupDomainController

Optional

String

FQDN of a domain controller where universal group information is stored.

GlobalCatalog

Optional

String

FQDN of a global catalog server in your domain. This parameter is not required if you are running Disable-CsComputer on a computer with an account in your domain.

GlobalSettingsDomainController

Optional

String

FQDN of a domain controller where global settings are stored. If global settings are stored in the System container in Active Directory Domain Services (AD DS), then this parameter must point to the root domain controller. If global settings are stored in the Configuration container, then any domain controller can be used and this parameter can be omitted.

RootDomainController

Optional

String

FQDN of the root domain controller, used to create trust paths for clients that need to access resources in domains other than their own.

Report

Optional

String

Enables you to specify a file path for the log file created when the cmdlet runs. For example: -Report "C:\Logs\DisableForest.html"

Force

Optional

Switch Parameter

If present, forces the rollback of the forest preparation steps even if Disable-CsAdForest detects that at least one of the domains in the forest is still prepared for Lync Server 2010. If not present, the command will fail if Disable-CsAdForest detects that at least one of the domains in the forest is still prepared for Lync Server 2010.

WhatIf

Optional

Switch Parameter

Describes what would happen if you executed the command without actually executing the command.

Confirm

Optional

Switch Parameter

Prompts you for confirmation before executing the command.

Input Types

None.

Return Types

None.

Example

-------------------------- Example 1 ------------------------

Disable-CsAdForest

The command shown in Example 1 rolls back the forest preparation tasks carried out by Enable-CsAdForest. Because the Force parameter is not included, the command will fail if Disable-CsAdForest detects that at least one of the domains in the forest is still prepared for Lync Server 2010. In that case, you will need to rolls back the domain preparation by running Disable-CsAdDomain.

-------------------------- Example 2 ------------------------

Disable-CsAdForest -Force

In Example 2, forest preparation is rolled back even if Disable-CsAdForest detects that at least one of the domains in the forest is still prepared for Lync Server 2010. Rollback is forced by including the Force parameter.