http://tux.cs.unlv.edu/wiki/index.php?title=Process_control&feed=atom&action=historyProcess control - Revision history2024-03-28T20:15:02ZRevision history for this page on the wikiMediaWiki 1.30.0http://tux.cs.unlv.edu/wiki/index.php?title=Process_control&diff=209&oldid=prevWilliams: Created page with "On UNLV CS servers you have a limited number of processes that you can create. Once you have exceeded that number, you will not be able to remotely log in. ===Finding a proc..."2018-01-14T01:19:12Z<p>Created page with "On UNLV CS servers you have a limited number of processes that you can create. Once you have exceeded that number, you will not be able to remotely log in. ===Finding a proc..."</p>
<p><b>New page</b></p><div>On UNLV CS servers you have a limited number of processes that you can create. Once you have exceeded that number, you will not be able to remotely log in.<br />
<br />
===Finding a process===<br />
<br />
Find the process ID (PID) by typing <code>ps -ef | grep ''username''</code><br />
<br />
You will see output like this<br />
<br />
<source lang="shell-session"><br />
UID PID PPID C STIME TTY TIME CMD <br />
janedoe 2233 2231 0 16:57 ? 00:00:00 /usr/sbin/sshd<br />
janedoe 2234 2233 0 16:57 pts/0 00:00:00 -sh<br />
janedoe 2254 2234 0 16:57 pts/0 00:00:00 ps -ef<br />
janedoe 2255 2234 0 16:57 pts/0 00:00:00 grep janedo<br />
</source><br />
<br />
===Killing a process===<br />
Killing your programs is important because it relieves the workload on the CPU, therefore making data process faster for every user. Here is how to kill a process:<br />
<br />
* <code>kill -9 ''PID''</code> where <code>''PID''</code> is replaced with the appropriate PID, such as 2233 from above<br />
<br />
If this does not work, try one the following<br />
* <code>kill -9 -1</code><br />
* <code>pkill -U ''username''</code><br />
<br />
===Running a process in the background===<br />
<code>ctrl-c</code> is typically used to terminate a process. You would usually use this when a program crashes or when you are executing a program with infinite loops.<br />
<br />
<code>ctrl-z</code> is used for running a program in the background. This will not terminate your process.<br />
<br />
===Learning more===<br />
Use <code>man ''command''</code> to learn more about any Linux command.</div>Williams