
Windows Server 2012 R2 상자에서 실행되는 Powershell 스크립트에서 Unlock-ADAccount를 사용하려고 합니다. 이것이 내가 얻는 것입니다:
PS C:\> unlock-adaccount
unlock-adaccount : The term 'unlock-adaccount' is not recognized as the name of a cmdlet,
function, script file, or operable program. Check the spelling of the name, or if a path
was included, verify that the path is correct and try again.
At line:1 char:1
나는 찾았다SpiceWorks 스레드RSAT를 설치해야 한다고 나와 있는데 Windows 10용입니다. Server 2012 R2에 RSAT를 설치해도 누락된 cmdlet이 수정됩니까?
답변1
이를 위해서는 다음 PowerShell 명령을 통해 설치할 수 있는 RSAT(원격 서버 관리 도구)가 필요합니다
Get-WindowsCapability -Name RSAT* -Online | Add-WindowsCapability -Online
.
이것이 설치되면 다음 PowerShell 명령을 사용하여 Active Directory PowerShell을 로드할 수 있습니다: Import-Module ActiveDirectory
또는 IPMO ActiveDirectory
.
완료되면 Unlock-ADAccount
관련 RSAT 모듈의 다른 명령과 함께 사용될 수 있습니다.
답변2
제가 그냥 멍청했던 것 같아요. 서버 관리자를 살펴보고 기능 -> 원격 서버 관리 도구 -> 역할 관리 도구 -> AD DS 및 AD LDS 도구에서 Windows PowerShell용 Active Directory 모듈 활성화를 클릭했습니다.