cmd命令修改IP和DNS(成功)

win7下的命令:
netsh interface ip set address name=”本地连接” source=static addr=10.0.0.2 mask=255.255.255.0 gateway=10.0.0.1
netsh interface ip set dns “本地连接” source=static addr=202.96.128.86
netsh interface ip add dns “本地连接” addr=202.96.128.166
====================================================================
XP系统下的命令:
netsh interface ip set address name=”本地连接” source=static addr=10.0.0.2mask=255.255.255.0
netsh interface ip set address name=”本地连接” gateway=10.0.0.1 gwmetric=0
netsh interface ip set dns name=”本地连接” source=static addr=202.96.128.86register=primary
netsh interface ip add dns name=”本地连接” addr=202.96.128.166 index=2

Article By :

2 thoughts on “cmd命令修改IP和DNS(成功)

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注