Datacrash Forum  


Change DNS server with Regfind on client computers - 2006/04/28 11:16 Regfind is a tool that can be found in the resourcekit of Windows 200X.

If you want to change DNS Server(s) on client computers use.

Code:

  regfind -p HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters <old DNS IP address > -<New DNS IP address>  for multiple dns servers  regfind -p HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters 10.11.12.13 -r 10.11.12.14 10.11.12.15 (etc)



On a remote computer
Code:

  regfind -m \\computername -p regfind -p HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters <old DNS IP address > -<New DNS IP address>



Post edited by: leon1e, at: 2006/04/28 21:01

Post edited by: leon1e, at: 2006/04/28 21:04 [/code:1]
GPO adicted
  | | The administrator has disabled public write access.
Re:Change DNS server with Regfind on client comput - 2006/07/16 21:28 A much better way would be to utilize 'netsh' for this as it uses the appropriate API calls instead of relying on an Windows internal structure.

The way to set a DNS would be like this:

Code:

 netsh interface ip set dns "Local Area Connection"  static x.x.x.x primary



Where 'x.x.x.x' is replaced by the IP addres of your DNS server.
  | | The administrator has disabled public write access.
Re:Change DNS server with Regfind on client comput - 2006/09/22 21:46 Or you can write an VBS script which connects to the clients WMI interface and change it through WMI. This way you don't have to go to every computer in the building but do it remotely !

Post edited by: ReneB, at: 2006/09/22 21:47
  | | The administrator has disabled public write access.