Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How xp modifies DNS

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >

Share

Shulou(Shulou.com)06/01 Report--

This article will explain in detail how xp modifies DNS for you. The editor thinks it is very practical, so I share it for you as a reference. I hope you can get something after reading this article.

In fact, it can be modified in the properties of the network card!

But the strange thing is that my wireless network card is not allowed to modify the DNS (after modification and restart, it is still restored to the original DNS), so I found the following blog, used netsh interface ip add DNS "wiareless" 192.168.10.10, and finally modified the DNS!

The first is to use the netsh command to modify the computer's IP address, subnet mask, default gateway and DNS.

@ echo off

Netsh interface ip set address "Local connection" static 192.168.0.1 255.255.255.0 192.168.0.254 1

Netsh interface ip set dns "Local connection" static 202.194.40.1

Netsh interface ip add dns "Local connection" 202.194.40.2 2

Note: the part shown in blue font above is the part that you need to modify. Among them, the "local connection" in the second, third and fourth lines generally does not need to be modified, which depends on your computer's right-click "Network neighbor" and select "Properties" to appear the connection name in the "Network connection" window. In general, there is only one "local connection".

In the second line, the three addresses of 192.168.0.1 255.255.255.0 192.168.0.254 are the IP address, subnet mask and default gateway, and replace them with the address you want to modify.

202.194.40.1 in the third line is the address of DNS, just change it to the DNS address you want to modify.

202.194.40.2 in the fourth line is the secondary DNS address, that is, the second, just change it to the second DNS address you want to modify, if not, you can delete the fourth line directly.

The second is to use the netsh command to modify the computer's IP address, subnet mask, default gateway and DNS for dynamic acquisition.

@ echo off

Netsh interface ip set address "Local connection" dhcp

Netsh interface ip set dns "Local connection" dhcp

Note: this is relatively simple, just according to the situation of your computer, modify the blue font marked "local connection", generally do not need to modify.

The following article is about the detailed usage of the netsh command. After reading it, you will understand some other uses of it.

In Windows 2000, you can use the netsh command to script the process of changing a computer's static Internet Protocol (IP) address to a dynamic Host configuration Protocol (DHCP) address or vice versa. The netsh command does not need to restart the computer to accomplish this task. This feature is especially useful for laptops that move from one environment to another when it must use a statically assigned IP address in one location and a DHCP-assigned IP address in another.

The method described in this paper is suitable for Windows 2000 and Windows Server 2003.

To switch the static address of the specified adapter to the DHCP address, type:

Netsh interface ip set address "Local connection" dhcp

Note: typing this command will change the interface named Local connection to DHCP.

To display all adapters in the computer and their current IP addresses to determine the correct adapter name, type:

Netsh interface ip show config

To change to a static address, type:

Hops of netsh interface ip set address "Local connection" static IP Mask Gateway

Such as:

Netsh interface ip set address "Local connection" static 192.168.0.10 255.255.255.0 192.168.0.1 1

Change DNS to 192.168.0.1:

Netsh interface ip set DNS "Local connection" static 192.168.0.1

Delete Gateway:

Netsh interface ip delete address "Local connection" gateway=all

Delete DNS:

Netsh interface ip delete dns "Local connection" all

If you are prompted to specify an invalid interface when performing the configuration, please turn on the "Remote Registry Service" service of the system.

Control panel-& gt management tools-- & gt services-- & gt opens Remote Registry Service

Modify ip, subnet mask, gateway, dns. "Network connection name" is the connection name seen in the network properties on your machine. Change the following to your own connection name.

This is the end of the article on "how xp modifies DNS". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it out for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Network Security

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report