1:设置自动获取IP
netsh int ip set address name="com1" source=dhcp netsh interface ip set dns com1 dhcp
2:设置静态IP
@echo ip_sisans netsh interface ip set address com1 source=static addr=192.168.1.246 mask=255.255.255.0 netsh interface ip set address name=com1 gateway=192.168.3.254 gwmetric=1 netsh interface ip set dns com1 static 10.10.10.10 netsh interface ip add dns com1 10.1.135.135
这个就是快速修改IP地址了.