How Win8 uses the command line to configure IP address

  
                

To configure the IP address for Win8, you can modify it in the network center properties, but the method to be introduced in this article is to configure the IP address of Win8 on the command line. This method is more direct and faster than the former, so let's take a look.

The specific steps are as follows:

1. Open a command prompt, enter netsh and press

2. Then enter the interface and press

3. Enter ip, enter

4. Enter set address “connection name” static new IP address subnet mask gateway 1, then enter

Note that the above commands need to be in accordance with user requirements To modify it, the connection name can be modified by referring to the name in “Network Connection”, which supports Chinese, but the quotation mark should be in English. There must be a space between each item, and finally enter "ldquo;1", which means OK. Refer to the following example:

set address <quo;Ethernet 3& rdquo; static 192.168.1.108 255.255.255.0 192.168.0.1 1

5. You can also enter the above command once, but make sure No line break: netsh interface ip set address <;connection name” static new IP address subnet mask gateway 1

Example: netsh interface ip set address <; Ethernet 3& rdquo; static 192.168.1.108 255.255.255.0 192.168.0.1 1

Alternatively, you can use a similar command to modify the DNS. The format is the same as above. Just replace "ld";address” with "dns"; netsh interface ip set dns “ Ethernet 3” static DNS address

Note that the system IP becomes static after modification. If it does not meet the user's needs, you can use the system's own network "troubleshooting" to automatically repair and restore the dynamic IP. Of course, you can also restore the IP address by using the command netsh interface ip set address <; connection name & rdquo; dhcp; similarly, the DNS address can also be restored by the command netsh interface ip set dns <; connection name & rdquo; dhcp.

The above is how Win8 uses the command line to configure the entire contents of the IP address. This method configures IP so that ordinary users have the feeling of being a programmer. Interested friends can try it.

Copyright © Windows knowledge All Rights Reserved