Uninstall-ADServiceAccount

Windows Server 2012 R2 and Windows 8.1

업데이트 날짜: 2015년 7월

적용 대상: Windows 8.1, Windows PowerShell 4.0, Windows Server 2012 R2

Uninstall-ADServiceAccount

Uninstalls an Active Directory managed service account from a computer or removes a cached group managed service account from a computer.

구문

Parameter Set: Default
Uninstall-ADServiceAccount [-Identity] <ADServiceAccount> [-AuthType <ADAuthType> {Negotiate | Basic} ] [-ForceRemoveLocal] [-Confirm] [-WhatIf] [ <CommonParameters>]




자세한 설명

The Uninstall-ADServiceAccount cmdlet removes an Active Directory standalone managed service account (MSA) on the computer on which the cmdlet is run. For group MSAs, the cmdlet removes the group MSA from the cache. However, if a service is still using the group MSA and the host has permission to retrieve the password, then a new cache entry is created. The specified MSA must be installed on the computer.

The Identity parameter specifies the Active Directory MSA to uninstall. You can identify an MSA by its distinguished name (DN), GUID, security identifier (SID), or Security Account Manager (SAM) account name. You can also set the parameter to an MSA object variable, such as $<localServiceAccountObject> or pass an MSA object through the pipeline to the Identity parameter. For example, you can use the Get-ADServiceAccount to get an MSA object and then pass that object through the pipeline to the Uninstall-ADServiceAccount cmdlet.

매개 변수

-AuthType<ADAuthType>

Specifies the authentication method to use. 이 매개 변수에 허용되는 값은 다음과 같습니다.

-- Negotiate or 0
-- Basic or 1

The default authentication method is Negotiate.

A Secure Sockets Layer (SSL) connection is required for the Basic authentication method.


별칭

없음

필수 여부

false

위치

named

기본값

Microsoft.ActiveDirectory.Management.AuthType.Negotiate

파이프라인 입력 적용 여부

false

와일드카드 문자 허용 여부

false

-ForceRemoveLocal

Indicates that you can remove the account from the local security authority (LSA) if there is no access to a writable domain controller. This is required if you are uninstalling the MSA from a server that is placed in a segmented network such as a perimeter network with access only to a read-only domain controller. If you specify this parameter and the server has access to a writable domain controller, the account is also un-linked from the computer account in the directory.


별칭

없음

필수 여부

false

위치

named

기본값

없음

파이프라인 입력 적용 여부

false

와일드카드 문자 허용 여부

false

-Identity<ADServiceAccount>

Specifies an Active Directory account object by providing one of the following property values. The identifier in parentheses is the LDAP display name for the attribute.이 매개 변수에 허용되는 값은 다음과 같습니다.

-- A Distinguished Name
-- A GUID (objectGUID)
-- A Security Identifier (objectSid)
-- A SAM Account Name (sAMAccountName)

The cmdlet searches the default naming context or partition to find the object. If two or more objects are found, the cmdlet returns a non-terminating error.

This parameter can also get this object through the pipeline or you can set this parameter to an object instance.


별칭

없음

필수 여부

true

위치

1

기본값

없음

파이프라인 입력 적용 여부

True (ByValue)

와일드카드 문자 허용 여부

false

-Confirm

cmdlet을 실행하기 전에 확인 메시지가 표시됩니다.


필수 여부

false

위치

named

기본값

false

파이프라인 입력 적용 여부

false

와일드카드 문자 허용 여부

false

-WhatIf

cmdlet이 실행될 경우 결과 동작을 표시합니다. cmdlet이 실행되지 않습니다.


필수 여부

false

위치

named

기본값

false

파이프라인 입력 적용 여부

false

와일드카드 문자 허용 여부

false

<CommonParameters>

이 cmdlet은 일반 매개 변수 -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer 및 -OutVariable을 지원합니다. 자세한 내용은 다음을 참조하세요. about_CommonParameters(http://go.microsoft.com/fwlink/p/?LinkID=113216).

입력

입력 유형은 cmdlet에 파이프할 수 있는 개체의 유형입니다.

  • None or Microsoft.ActiveDirectory.Management.ADServiceAccount

    A managed service account object is received by the Identity parameter. A parameter with name ForceRemoveLocal is provided to un-install standalone MSAs on a read-only domain controller site.


출력

출력 유형은 cmdlet이 내보내는 개체의 유형입니다.

  • None

참고

  • This cmdlet does not work with AD LDS.

  • This cmdlet does not work with an Active Directory snapshot.

  • This cmdlet does not work with a read-only domain controller.

예제

Example 1: Uninstall a specified MSA

This command uninstalls the MSA identified as SQL-SRV1 from the local machine.


PS C:\> Uninstall-ADServiceAccount -Identity SQL-SRV1

Example 2: Uninstall an MSA from a server in a read-only domain controller site

This command uninstalls the specified standalone MSA from a server located in a read-only domain controller site such as a perimeter network.


PS C:\> Uninstall-ADServiceAccount -Identity sql-hr-01 -ForceRemoveLocal

관련 항목

커뮤니티 추가 항목

추가
표시: