HodgeHi Posted August 27, 2009 Posted August 27, 2009 Good evening, I was just wondering if anyone has used the JoinDomainOrWorkgroup function/command. I am looking at it for a possible method to script my XP partitions to join the AD after being re-imaged. I thought a script to lookup the active hardware/mac address and finding the corresponding Hostname, renaming the machine using this looked up hostname and then joining the AD. Has anyone got an example and possibly a description of what each bit does? This should be good if i can get it to work. Would be a fully deployed XP/OS X machine from bare-metal to fully up and running. TIA
Michael Posted August 27, 2009 Posted August 27, 2009 I am looking at it for a possible method to script my XP partitions to join the AD after being re-imaged. You can use Sysprep to create an answer file so after imaging, your XP machine automatically joins the domain. As for OS X I'm not sure if you can automate it to join a Windows domain. I'm not a Mac expert, but hopefully someone else can help.
somabc Posted August 27, 2009 Posted August 27, 2009 (edited) You certainly can Mac OS X Manual Page For dsconfigad(8) eg dsconfigad -a ThisComputer -u "administrator" -ou "CN=Computers,OU=Engineering,DC=ads,DC=demo,DC=com" -domain domain.ads.apple.com Edited August 27, 2009 by somabc
MatthewL Posted August 27, 2009 Posted August 27, 2009 We have ours join our domain, name up as the Dell service tag and then place the computer account in a certain OU rather than the Computers OU.
Ric_ Posted August 28, 2009 Posted August 28, 2009 You certainly can Mac OS X Manual Page For dsconfigad(8) eg dsconfigad -a ThisComputer -u "administrator" -ou "CN=Computers,OU=Engineering,DC=ads,DC=demo,DC=com" -domain domain.ads.apple.com Or you could hack the script at http://www.edugeek.net/wiki/index.php/Changing_the_computername_and_joining_Open_Directory_and_Active_Directory a bit to fully automate things.
HodgeHi Posted August 28, 2009 Author Posted August 28, 2009 Or you could hack the script at http://www.edugeek.net/wiki/index.php/Changing_the_computername_and_joining_Open_Directory_and_Active_Directory a bit to fully automate things. I do this as part of the deploystudio imaging process. No scripting needed, just tick a few boxes and enter a few details This suits me well @MatthewL Do you use the joindomainorworkgroup for this? If so have you got an example that you could share of the script you use?
MatthewL Posted August 28, 2009 Posted August 28, 2009 I'm not sure at the moment as I am now on leave for a week and I dont want to log back in on the laptop to check as I will only get involved doing other bits. When I get chance I will have a look.
MatthewL Posted September 9, 2009 Posted September 9, 2009 (edited) Just got back into the office and had a look at our sysprep.ini file for networking identification shows the following: [identification] JoinDomain={DOMAIN} DomainAdmin={DOMAIN}\oursysprepusername DomainAdminPassword=ourpassword! MachineObjectOU = "OU = Sysprep,OU = CTP, OU = Computers, OU = {OU},DC = {DOMAIN},DC = {DC},DC = UK" Edited February 24, 2021 by ZeroHour
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now