I need to keep hosts files up to date in a simple way. I want to read a list of servers from a text file int a script, rename the existing file on the server to hosts.old, if hosts.old exists then rename it to host. with the time stamp appended. then copy the new hosts file from a central location. Then if something messes up I would like to be able to undo what was just done.
Maybe something like "hostscript.cmd new" and then "hostscript.cmd undo".
Then write out a log file to list servers updated and time and list any servers that did not get updated, like if one was shut down at the time.
Then make a nice cafe mocha and clean my house when it is done.
Mike
Bump. Anyone?
Yes (14) | ![]() | |
No (14) | ![]() | |
I don't know (15) | ![]() |