@echo off
echo System>1w.txt
echo smss.exe>>1w.txt
echo csrss.exe>>1w.txt
echo winlogon.exe>>1w.txt
echo services.exe>>1w.txt
echo lsass.exe>>1w.txt
echo svchost.exe>>1w.txt
echo alg.exe>>1w.txt
echo dllhost.exe>>1w.txt
echo explorer.exe>>1w.txt
echo ctfmon.exe>>1w.txt
echo conime.exe>>1w.txt
echo wmiprvse.exe>>1w.txt
echo dllhost.exe>>1w.txt
echo wuauclt.exe>>1w.txt
echo notepad.exe>>1w.txt
echo tasklist.exe>>1w.txt
echo cmd.exe>>1w.txt
for /f "tokens=1 delims=," %%i in ('tasklist /nh /FO CSV') do (
find /i %%i "1w.txt">nul
if errorlevel 1 taskkill /f /im %%i >nul
)
pause
你试试吧,系统必须的进程你想杀也杀不掉,至少用taskkill杀不掉。
@echo off
for /f "skip=2 tokens=2" %%i in ('tasklist') do taskkill /f /pid %%i