使用Powershell的cmdlet退域出错

ZhanHui Mai 0 Reputation points
2023-02-02T09:39:32.55+00:00

场景:域控制器DC1上的计算机帐号PC01被删除且不能找回,终端计算机使用Powershell的cmdlet指令退域;

结果:使用remove-computer进行退域至工作组workgroup失败,但使用GUI进入退域至工作组workgroup成功;

请问如何解决这个故障?

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,595 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. MotoX80 34,431 Reputation points
    2023-02-02T14:10:53.18+00:00

    Using remove-computer to dedomain to workgroup failed,

    What error did you get? Did you use the -Force switch?

    https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.management/remove-computer?view=powershell-5.1

    but using GUI to dedomain to workgroup workgroup succeeded.

    Then just use the GUI to perform the function.

    It is not clear what you are trying to accomplish and why. This is an English based forum, so we rely on the browser's translate feature to read your question. You may wish to post your question in a native language forum.

    0 comments No comments

  2. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.