Rename a Windows computer using command line powershell Feb 18, 2014 netdom renamecomputer "$env:COMPUTERNAME" /Newname "myname"