OK. I am trying to run a very simple script...

@echo off

SET DNS1=10.172.1.10

SET DNS2=10.172.1.9

netsh interface ipv4 add dnsservers "Local Area Connection" %DNS1%

netsh interface ipv4 add dnsservers "Local Area Connection" %DNS2% index=2

 

I have a whole buch of machines (all win 2008 R2) that are going to need their DNS changed.

This batch file works flawlesly in an elevated command prompt.

I have been trying to run it from K1000 without success

Can someone shed some light as to how I can get this working??...I've been pulling my hair out !!!

2 Comments   [ + ] Show Comments

Comments

  • Have you tried running this as System?
  • you can also run via a vbs file as system this way
    http://www.itninja.com/blog/view/how-to-hide-running-a-batch-file-from-a-kscript-with-version-5-5
Please log in to comment

There are no answers at this time

Answers

Answer this question or Comment on this question for clarity