Change Computer Name + Join Domain Through Batch File
Posted on 2004-08-06
I currently am going through the process of upgrading quite a few computers from windows 98 to 2000. We're cross-trading, so I give person A a new computer, and take their old one, and set it up with 2000 for person B, so that no person is left without a computer. This means I can't use the same computer names that the new and old computers use because we cant have 2 of the same name on the domain.
What I want to be able to do is change the computer name (and then reboot, putting a second batch file in HKEY...RunOnce) and use the second batch file to join the computer to our domain, essentially making this process unattended (like the rest of my windows 2000, upgrades, and software install). I have the means to either determine what computer name to use or to prompt for a computer name, that's no problem. I just want to know if there's a net command or some other type of command that will change my computer's name through a batch file. I have no problems using .reg files as well.
If you could provide me with the syntax for any such commands, i would appreciate it. I'm offering 200 points if you can tell me how to change the computer name through batch file/reg file, and 300 if you can tell me how to join the domain.