新增一個檔案,xxxxx.bat

例1:使用公司內部的設定

檔案名稱DHCP-DNS.bat  

檔案內容
@echo off
netsh interface ip set address "區域連線" dhcp
netsh interface ip set dns "區域連線" dhcp
netsh interface ip set wins "區域連線" dhcp

例2:使用Hinet 的DNS Server

檔案名稱Hinet-DNS.bat

檔案內容
@echo off
netsh interface ip set address "區域連線" dhcp
netsh interface ip set dns "區域連線" static 168.95.1.1
netsh interface ip set wins "區域連線" dhcp

例3:完全手動配置IP
IP:192.168.1.1
遮罩:255.255.255.0
閘道:192.168.1.254

檔案名稱MIP.bat

檔案內容
@echo off
netsh interface ip set address "區域連線" static 192.168.1.1 255.255.255.0 192.168.1.254 1                                                      
netsh interface ip set dns "區域連線" static 168.95.1.1

 PS:區域連線是網路介面卡的名稱,有些人可能是區域連線2或是其他的名稱,依照實際情況修改

arrow
arrow
    全站熱搜

    阿博 發表在 痞客邦 留言(0) 人氣()