Setting an IPv4 configuration - netsh
For example, if you want to configure the Local Area Connection interface with an IPv4 address 10 .0 .0 .11, a subnet mask 255 .255 .255 .0, and a default gateway 10 .0 .0 .11, you enter the following command:
netsh interface ipv4 set address "local area connection" static 10.0.0.11 255.255.255.0
10.0.0.11
If you also wanted to set the DNS server address as 10 .0 .0 .11, you enter the following command:
netsh interface ipv4 set dnsservers "local area connection" static 10.0.0.11
If you wanted the interface to obtain its IPv4 configuration automatically (dynamically), you enter the following commands:
netsh interface ipv4 set address name="local area connection" source=dhcp
netsh interface ipv4 set dnsservers name="local area connection" source=dhcp

Postar um comentário