从办公到家庭环境,或者从会议室到办公工位上的IP切换相信已经把你搞的烦死了,win7系统下载那么用下面的2个小脚本吧,呵呵,药到病除。8 J# K- e# Y+ [( h0 a! G
1. 切换成自动获取IP
" V8 c1 W2 ?) ^4 \/ z. C5 D1 e5 m @echo off
5 h% T' @+ e8 r9 W) M4 F+ W. P netsh interface ip set address name=“local” source=dhcp2 _6 [1 ~2 P4 D7 b w7 @
netsh interface ip set dns name=“local” source=dhcp
7 t7 s" [0 t1 r `2 \) c 2. 切换成固定IP, {8 H9 I8 {, {5 ^+ ^
@echo off. j& x- ]3 e5 O: ?% K& Q) F4 o
netsh interface ip set address local static 192.168.0.84 255.255.255.0 192.168.0.254
) d+ ?; S% \6 |" v @4 X8 Q. \ netsh interface ip set dns local 192.168.0.254
6 u1 n, z7 M* }4 a1 r4 y% ~ e3 S netsh interface ip add dns local 202.106.196.115 index=2; h4 m, C# m& ?; L0 }' o
netsh interface ip add dns local 202.106.0.20 index=37 O5 c& c* J' i8 b& d
“local” 是你的本地网卡名称,也可能是 “本地连接”,需要自己替换下。xp系统下载如果是2个固定IP间的来回切换,把第2个脚本自己改改吧 :)! k( O# F9 \) ~3 D9 L; j; E7 R8 V
dns设置中,第一个是set,表示设置,后面两个则是添加,自己替换成当地的dns server。( X0 `7 w1 s5 ^. m6 h5 f
|