The error indicates a broken secure channel (trust relationship) between the VM and the domain. The built‑in local Administrator password failure is a separate issue: either the local password is no longer what is expected (for example, due to restore/rollback) or the account being used is not actually the local Administrator.
From the provided information, the supported recovery paths are:
- Repair the secure channel (if you can get any remote/console access with domain creds)
If a domain account can still log on (for example via PowerShell remoting from another machine where domain auth works), repair the machine account password/secure channel:
Or, from an interactive session on the server (if you can get one):$cred = Get-Credential # domain admin credentials Invoke-Command -ComputerName "Server01" -ScriptBlock { Reset-ComputerMachinePassword -Credential $using:cred }
Then restart the server.Test-ComputerSecureChannel -Repair -Credential * - If secure channel repair fails: remove and re‑join the domain
Once you have any working logon (local or domain), use PowerShell to unjoin and rejoin:
# Unjoin Remove-Computer -UnjoinDomaincredential Domain01\Admin01 -PassThru -Verbose -Restart # After reboot, log on with local admin, then rejoin Add-Computer -ComputerName Server01 -LocalCredential Server01\Admin01 ` -DomainName Domain02 -Credential Domain02\Admin02 -Restart -Force - If no credentials work at all (local or domain)
The documentation in context does not provide a supported procedure to reset a forgotten/invalid local Administrator password on a domain‑joined server. In this situation, and especially for a production Windows Server 2025 VM, this becomes a support case:
- For Azure VMs: use the platform tools first (Reset password / VMAccess extension, Serial Console, redeploy, etc.). If those do not restore access, open an Azure support request.
- For on‑prem or non‑Azure virtualization: engage Microsoft Support, as offline password manipulation or unsupported SID/identity changes can break security and supportability (especially with clustering/SQL/AD roles).
Given that both domain logon (trust) and local Administrator logon are failing, and no supported local password reset method is documented in the provided material, this should be treated as a Microsoft engineering/support request after attempting secure‑channel repair from another machine if possible.
References:
- Broken trust relationship between a domain-joined device and its domain due to secure channel issues
- Active Directory has a newer password value than the client device
- Troubleshoot a failed trust relationship in an Azure Windows VM
- Reset Remote Desktop Services or its admin password on a Windows VM
- Can't access Hyper-V virtual machines via VMConnect