How to modify the IP address, DNS, and gateway of the network through the command line (Windows)

Source: Internet
Author: User

This technique is very useful for friends who often use laptops for business trips, such as in another environment, such as the customer's company, you always need to change the network to someone else's intranet address, gateway, DNS, and so on. Write a batch processing file, and then change it to the next one. It's faster than the mouse operation.

Form: http://blog.csdn.net/zmxj
Modify the IP address, subnet mask, gateway, and DNS. The "network connection name" is the connection name displayed in the Network Properties on your machine. Change the following name to your own connection name.
Netsh interface IP Set address "network connection name" static 192.168.0.88 255.255.255.0 192.168.0.1 1
Netsh interface IP Set DNS "network connection name" static 202.216.224.66
Netsh interface IP add DNS "network connection name" 202.216.224.67

If you want to change to dynamic IP Address Allocation and automatic DNS access, use the following command.
Netsh interface IP Set address "network connection name" DHCP
Netsh interface IP Set DNS "network connection name" DHCP


Your ad here

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.