Reset computer account password in a domain

I tried to logon to a computer  that wasn’t used for 18 months.

I got message “The trust relationship between primary domain and this workstation failed” while logging on.

A few PowerShell commands helped to fix the issue:

http://blog.blksthl.com/2013/03/18/fix-the-trust-relationship-between-this-workstation-and-the-primary-domain-failed/


Solve the problem by resetting the Computer password in Active Directory and on the Local machine, for this we use a PowerShell CMDlet called Reset-ComputerMachinePassword. Type in the following command:

Reset-ComputerMachinePassword -Server <Name of any domain controller> -Credential <domain admin account>

or

NETDOM RESETPWD /Server:<name of any domain controller> /UserD:<domain admin account> /PasswordD:<password>

About the Author