无线网卡:
netsh interface ip set address name="WLAN" source=static addr=192.168.100.249 mask=255.255.255.0 gateway=192.168.100.1 gwmetric=1
netsh interface ip add address name="WLAN" addr=192.168.110.249 mask=255.255.255.0 gateway=192.168.110.1 gwmetric=1
netsh interface ip add address name="WLAN" addr=192.168.3.249 mask=255.255.255.0 gateway=192.168.3.1 gwmetric=1
有线网卡:
netsh interface ip set address name="以太网" source=static addr=192.168.100.249 mask=255.255.255.0 gateway=192.168.100.1 gwmetric=1
netsh interface ip add address name="以太网" addr=192.168.110.249 mask=255.255.255.0 gateway=192.168.110.1 gwmetric=1
netsh interface ip add address name="以太网" addr=192.168.3.249 mask=255.255.255.0 gateway=192.168.3.1 gwmetric=1
最后,加上DNS
netsh interface ip set dns name="WALN" source=static addr=119.29.29.29 register=primary
netsh interface ip add dns name="WLAN" source=static addr=114.114.114.114 index=2
netsh interface ip set dns name="以太网" source=static addr=119.29.29.29 register=primary
netsh interface ip add dns name="以太网" source=static addr=114.114.114.114 index=2
恢复DHCP获取
netsh interface ip set address name="WLAN" source=dhcp
netsh interface ip set address name="以太网" source=dhcp
netsh interface ip set address name="WLAN" source=dhcp
netsh interface ip set address name="以太网" source=dhcp