1

I've enabled winrm, disabled firewall, enable remoting, GPOs for winrm, enabled SMBv1 and completed updates first as troubleshooting but I still get the error. I can ping the DC as well.

The error I get is:

Add-Computer: Computer "server2019' failed to join domain 'dev.domain.com' from its current workgroup 'WORKGROUP' with following error message: An internal error occurred.
At line:1 char:1
Add-Computer -DomainName dev.domain.com -OUPath "OU=$OU,dc=dev,dc=domain,dc=com" ...

CategorvInfo :Operation5topped: (server2019:5tring) [Add-Computer]
. InvalidoperationException
+ FullvOualifiedErrorId:FailToJoinDomainFromworkgroup,Microsoft.PowerShell.Commands.AddComputerCommand

Here is the part of my script that does the join:

     [String]$OU,
     [PSCredential]$Credential
     )
    
 $ErrorActionPreference="SilentlyContinue"
 Stop-Transcript | out-null
 $ErrorActionPreference = "Continue"
    
    
 if ([Environment]::UserInteractive) {
     if (!$OU) { $OU = Read-Host "Enter Resource Pool Name (exactly as appears in vCenter inventory)" }
     if (!$Credential) { $Credential = Get-Credential -Message "Enter dev domain credentials" }
 }
    
 # Add Computer to Dev domain
    
 try {
     Add-Computer -DomainName dev.domain.com -OUPath "OU=$OU,dc=dev,dc=domain,dc=com" -ErrorAction stop -Credential $Credential
     }
 catch {
     Write-Warning "Failed to join to domain."
         Read-Host -Prompt "Press Enter to exit"
     Throw $_
     }
PS C:\Windows\ system32> nltest.exe/dsgetdc:dev.domain.com
DC: \\devad02.dev.domain.com
Address: \\10.1.214.29
Do Guid: ae3bef55-dd18-4598-b809-2058516e6abl
Dom Name: dev.domain.com
Forest Name: dev.domain.com
De Site Name: SITE
Our Site Name: SITE
Flags: GC DS LDAP KDC TIMESERV WRITABLE DNS_DC DNS_DOMAIN DNS_FOREST CLOSE_SITE FULL_SECRE
TWS D5_8 D5_9 D5_10 0x20000
The command completed successfully

Edit: Server Manager showed an error Event for NetJoin that gave error code 1359 I tried running:

nltest /dclist:MYDOMAIN and got: You don't have access to DsBind to dev.domain.com

I also tried running: nltest /server:UserSyncServer /sc_reset:domain\devdc and got: I_NetLogonControl failed: Status = 1722 0x6ba RPC_S_SERVER_UNAVAILABLE

15
  • 3
    nltest /dsgetdc:dev.domain.com
    – Greg Askew
    Apr 8, 2022 at 17:10
  • 1
    @GregAskew i do get a successful result from that. it shows the dc, address, dom name and guid, site name and flags Apr 8, 2022 at 17:13
  • 1
    @GregAskew posted in question Apr 8, 2022 at 17:20
  • 1
    Silly question, but is the clock on the joining machine sync'd to your domain's time? Apr 8, 2022 at 17:26
  • 1
    @EvanAnderson it wasn't. I set the time by running a w32tm config. The source was originally microsoft but I still get the same results after restarting Apr 8, 2022 at 18:16

2 Answers 2

1

Microsoft suggested changing the MsDS-SupportedEncryptionTypes to AES from RC4 on the domain controllers, but What worked for me was removing and re-adding the trust between DCs that was outgoing and forward transitive.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.