Netcmd.bat
Copy Code code as follows:
#windows常用网络命令
#查看本地网卡接口信息
Ipconfig/all
#ping (often used to test network connectivity)
Ping www.baidu.com
#路由相关
#1. View the routing table (where 0.0.0.0 records are the default route configuration)
Route print
#2. Add routes (if you add the-p parameter to indicate adding a permanent route)
Route add 192.168.1.0 Maks 255.255.255.0 192.168.1.11
#3. Delete route
Route Delete 192.168.1.0
#4. Trace Route
Tracert www.baidu.com
#地址解析 (Map of IP address to MAC address)
Arp-a
#网络配置 (Network connection command line configuration Interface)
#导出本地网络连接配置信息
netsh interface ip dump > d:/netconfig.txt
#导入网络配置
Netsh exec d:/netconfig.txt
#设置本地连接通过dhcp自动配置
netsh interface ip set address "Local Area Connection" DUHP
#设置本地连接静态IP
netsh interface ip set address "Local Area Connection" Static 192.168.1.11 255.255.255.0 192.168.1.1
#查看域名信息 (can get the IP address of the domain name)
Nslookup baidu.com