命令行配置Windows网卡IP地址抢沙发

2013-06-21    分类:命令收集      

0. 如何获取网络连接的名称?

netsh interface ip show interfaces

1. 重置IP地址:

netsh interface ip set address “本地连接” static 192.168.1.10 255.255.255.0 192.168.1.1 0 #最后的0表示跃点数是自动

2. 添加IP地址:

netsh interface ip add address “本地连接” 192.168.1.11 255.255.255.0 192.168.1.1 0

netsh interface ip add address “本地连接” 192.168.1.11 255.255.255.0 #如果要添加的IP的网关已存在,则可不用再注明网关

3. 删除IP地址:

netsh interface ip delete address “本地连接” address=192.168.1.11

4. 删除网关:

netsh interface ip delete address “本地连接” gateway=192.168.1.1    #如果gateway=all则会删除所有网关

5. 删除IP和网关可以合并为一条命令:

netsh interface ip delete address “本地连接” address=192.168.1.11 gateway=192.168.1.1

 

 

转载请注明:悠悠猴 » 命令行配置Windows网卡IP地址

继续查看有关 的文章

相关文章

我来说说

发表评论您必须先登录