Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

join computer to domain powershell script

$dc = "ENTERPRISE"
$pw = "Password123" | ConvertTo-SecureString -asPlainText -Force
$usr = "$dcT.Simpson"
$pc = "R07GF"
$creds = New-Object System.Management.Automation.PSCredential($usr,$pw)
Remove-Computer -ComputerName $pc -Credential $creds –Verbose –Restart –Force
Source by blog.netwrix.com #
 
PREVIOUS NEXT
Tagged: #join #computer #domain #powershell #script
ADD COMMENT
Topic
Name
5+8 =