First, run command prompt as administrator, then type the following command and press enter for each line :
netsh interface ipv4 set dnsservers "Local Area Connection" static 8.8.8.8 primary
netsh interface ipv4 add dnsserver "Local Area Connection" 8.8.4.4 index=2
netsh interface ipv4 add dnsserver "Local Area Connection" 8.8.4.4 index=2
Note :
- Change 8.8.8.8 or 8.8.4.4 with your DNS Server.
- First line is to set or change primary / preferred dns server.
- Second line is to add secondary / alternate dns server.
- Change "Local Area Connection" with your machine's interface name.To find the name of interface use the following command :
netsh interface show interface
or
netsh interface ipv4 show config
If you want to set obtain DNS Server address automatically, use the following command :
netsh interface ipv4 set dnsservers "Local Area Connection" dhcp
No comments:
Post a Comment