- Open the Terminal Application
- Type in
sudo -iand type in your Mac Administrator account password.sudogives you root level or administrator level privileges.
dsconfigad -show
dsconfigad -remove -username
<username>-password<password>[-localuser<localadmin>-localpassword<localpass>]
Note: <username> needs to be replaced with domain administrator who has binding/unbinding rights.
<computer-name> --> replace this with the computer name you want to bind to Active Directory
<username> --> needs to be replaced with domain administrator who has binding/unbinding rights.
<domain> --> replace with domain you want to join.
dsconfigad -add
<domain>-computer<computer-name>-username<username>-password<password>-ou "CN=Computers,DC=network,DC=example,DC=com" [-force] [-localuser<localadmin>-localpassword<localpass>] -mobile enable -mobileconfirm enable -localhome enable -useuncpath enable -protocol smb -groups "Domain Admins,Enterprise Admins" -alldomains enable -packetsign require -packetencrypt require
<computer-name> --> replace this with the computer name you want to bind to Active Directory
<username> --> needs to be replaced with domain administrator who has binding/unbinding rights.
<domain> --> replace with domain you want to join.
dsconfigad -add
<domain>-computer<computer-name>-username<username>-password<password>-ou "CN=Computers,DC=network,DC=example,DC=com" [-force] [-localuser<localadmin>-localpassword<localpass>] -localhome enable -useuncpath enable -protocol smb -groups "Domain Admins,Enterprise Admins" -alldomains enable -packetsign require -packetencrypt require
Is there special syntax associated with the -u and -p for unbinding? I don't want to force unbind leaving cruft in AD. I keep getting "Invalid Credentials supplied to remove the bound server" I've tried:
For -u
ou\admin-account
ou\admin-account
admin-account
For -p
pa$$w0rd^
pa$$w0rd^
NOTE - these are random credentials but I am structuring them here to be very similar, including the $ in the password.
I believe bash is messing with my credentials...If I echo the password with the "" in front of the $ signs, it echos properly. If I echo ou\admin-account with the additional , it echoes properly.
Help please :D