windows常用命令(持续更新)

通过pid查命令行

 wmic process where processid=6588 get commandline

通过pid查内存使用情况

tasklist /FI "PID eq 3432"

检查某个端口连接状态并计算连接数总和

netstat -ano|findstr "6379"
netstat -ano|findstr "6379"|find  /C ":"
netstat -ano|findstr "6379"|find  /C "ESTABLISHED"
netstat -ano|findstr "6379"|find  /C "TIME_WAIT"
查看TIME_WAIT连接数:
netstat -ano|find "TIME_WAIT" /c
查看ESTABLISHED连接数:
netstat -ano|find "ESTABLISHED" /c



image

查询并修改端口范围

#查询
netsh int ipv4 show dynamicportrange tcp
#修改
netsh int ipv4 set dynamicport tcp start=15000 numberofports=50000

image
image
image

posted @ 2025-05-20 16:34  海yo  阅读(25)  评论(0)    收藏  举报