Linux常用命令: 系統(tǒng)進程管理

放心~被指到的人一定能學會的~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~?
其他命令使用場景分類:?https://www.bilibili.com/read/cv22241446
ps
顯示執(zhí)行進程信息
lsof
列表顯示進程打開的文件信息
顯示其他用戶的打開文件時需要root權限
kill
給進程發(fā)送信號的命令,一般用來終止進程
?
?
1. ps
Information about running processes.
顯示執(zhí)行進程信息
??List all running processes(顯示所有的執(zhí)行進程信息):
??List all running processes including the full command string(顯示所有的執(zhí)行進程信息,包括完整的命令名):
??Search for a process that matches a string(從所有進程信息中搜索內容):
2. lsof
Lists open files and the corresponding processes.
列表顯示進程打開的文件信息
Note: Root privileges (or sudo) is required to list files opened by others.
顯示其他用戶的打開文件時需要root權限
??Find the processes that have a given file open(找到占用文件的進程):
??Find the process that opened a local internet port(找到占用端口的進程):
??List files opened by the given command or process(顯示指定命令或進程占用的文件):
?
3. kill
Sends a signal to a process, usually related to stopping the process.
給進程發(fā)送信號的命令,一般用來終止進程
??Terminate a program using the default SIGTERM (terminate) signal(通過終止信號結束進程):
??List available signal names (to be used without the?SIG?prefix)(顯示所有可用信號,用的時候不用寫SIG前綴或者使用信號代號):
kill -l
??Terminate a background job(終止后臺任務):
??Signal the operating system to immediately terminate a program (which gets no chance to capture the signal)(立即終止進程):
?

自學筆記~
如果有錯~
期待大佬指出~
感謝幫助提升~?