[問題] 如何以root暫停user的工作?
linux 底下,我知道可以用Ctrl+z來暫停工作,然
後用fg jobs來重新啟動。但如果是root,要怎麼暫停
某一個特定工作了(如果知道PID),又如何重啟呢?
先感謝各位了!
(root 都可以kill某一個特定工作,暫停應該是可以達到的吧。)
自問自答一下,在以下網頁,找到了方法。
http://www.comptechdoc.org/os/linux/usersguide/linux_ugprocesses.html
節錄自上方網址,
kill -STOP 1721 Stops (suspends) process 1721 by sending
the STOP signal to the process. This process
will still be on the task list. The process
can't catch or ignore the STOP signal.
kill -CONT 1721 Continue process 1721 causing it to resume.
The CONT signal is sent to the process.
現在產生一個新的問題,我要怎麼查詢有哪些工作是被stop,然後其pid為何?
在usr使用下,jobs就可以查詢了。但現在是root,怎麼知道有哪些工作是在stop
狀態?不然,若是把工作stop後,要如何把它回覆。
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.187.168
※ 編輯: fullvacuum 來自: 140.112.187.168 (03/20 19:36)
推
03/20 20:15, , 1F
03/20 20:15, 1F
→
03/20 20:31, , 2F
03/20 20:31, 2F
Linux 近期熱門文章
21
56
PTT數位生活區 即時熱門文章