Recently after a Hyper-V migration, one of our servers gave us this dreaded message “The trust relationship between this workstation and the primary domain failed”

I really didn’t feel like removing it from the domain and re-adding it causing all sorts of SID problems.

According to the Microsoft TechNet article:  http://technet.microsoft.com/en-us/library/hh849751.aspx

The Reset-ComputerMachinePassword cmdlet changes the machine account password that the computers use to authenticate to the domain controllers in the domain.

 

Log on locally, run the powershell command and your problem is now sorted.