Skip to main content

DNS Entries

  • March 12, 2021
  • 1 reply
  • 53 views

Forum|alt.badge.img

Can a worklet update DNS entries under network setting on machines?

1 reply

  • Novice
  • 35 replies
  • March 13, 2021

Yes, you could use something quick and simple like the following below to set your primary and secondary DNS addresses. The Get-DnsClientServerAddress will return the output of your changes to the Reports > Activity section in Automox, you can add -Verbose to the end of each command for more detail if you wish too


Note that the “Ethernet*” in -InterfaceAlias will target all network adapters on the device named “Ethernet” (if there is more than one)


Change “8.8.8.8” and “1.1.1.1” in -ServerAddresses to your specified DNS address.


Be sure to test this first.


Evaluation:


exit 0


Remediation:


Set-DnsClientServerAddress -InterfaceAlias "Ethernet*" -ServerAddresses @("8.8.8.8","1.1.1.1")

Get-DnsClientServerAddress -InterfaceAlias "Ethernet*" | Select InterfaceAlias,ServerAddresses

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings