Jan 5, 2023

Batch : Rename Hostname

 Inside batch file, create the following command line to rename the current computer with a new hostname.

WMIC COMPUTERSYSTEM where name="%COMPUTERNAME%" CALL RENAME name="%NEWPCNAME%"

Need to restart computer to take effect.


!!! HAPPY COMPUTING !!!


No comments:

Post a Comment