sir*_*ank 4 powershell active-directory gmsa
我创建了一个这样的 gMSA:
New-ADServiceAccount -name Cust00000 -DNSHostName Cust00000.domain.com -PrincipalsAllowedToRetrieveManagedPassword "IIS_IUSRS" -ManagedPasswordIntervalInDays 60
Run Code Online (Sandbox Code Playgroud)
而生活似乎也很美好。然而,当我跑步时
Test-ADServiceAccount Cust00000
Run Code Online (Sandbox Code Playgroud)
这就是我得到的:
False
WARNING: Test failed for Managed Service Account Cust00000. If standalone Managed Service Account, the account is
linked to another computer object in the Active Directory. If group Managed Service Account, either this computer does
not have permission to use the group MSA or this computer does not support all the Kerberos encryption types required
for the gMSA. See the MSA operational log for more information.
Run Code Online (Sandbox Code Playgroud)
我检查了事件查看器 -> 应用程序和服务日志 -> Microsoft -> Windows -> 应用程序 -> Microsoft-Windows-TWinUI/Operational,但这似乎不正确。MSA 操作日志在哪里(可能是什么)?
编辑:对于整体问题,我已经尝试过,Install-ADServiceAccount但没有成功。我放弃了这一点,并最终让它工作(对于名为 Domain\sirdank$ 的 gMSA),Set-ADServiceAccount sirdank -PrincipalsAllowedToRetrieveManagedPassword "$env:computername$"我也很幸运地传递了“域计算机”而不是“$env:computername$”。
现在有类似的问题。我认为您要查找的日志位于 Microsoft/Windows/Security-Netlogon/Operational log 下的事件查看器中;您可能会看到一些 9001/9002 事件(MSA 的任务类别),这可能会让您对正在发生的事情有一些了解。
这是从最近的一篇 TechNet 博客文章中获得的,该文章描述了对 gMSA 帐户创建/测试问题进行故障排除。看一下,它可能与您的整体问题相关:https://blogs.technet.microsoft.com/joelvicery/cannot-install-service-account-the-provided-context-did-not-match-the-target /
备用链接(看来同一篇文章以不同的标题交叉发布): https: //blogs.technet.microsoft.com/runcmd/the-rc4-removal-files-part-1-whats-in-an-错误信息/