Ask the Expert

How can I rename a PC and rejoin a domain via script or batch file?

I work with over 4,500 workstations (NT/Win2k/XP) in our NT 4.0 domain. We are being asked to change the host names on all of them. We have software that lets me push apps, batch files and scripts to execute on the destination PC. If I could create a script to rename a PC and rejoin a domain, I could send it out in mass. How can I rename a PC and rejoin a domain via script or batch file?

Requires Free Membership to View

Basically, with the right permissions you can use the NETDOM tool. There is a newer version of the tool in the Windows XP and Windows 2003 resource kit. This tool will allow for the renaming and rejoining of the workstation to the domain.

This was first published in June 2003

There are Comments. Add yours.

TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: