Monitoring and terminating processes at the command line


Article from Issue 66/2006

Innumerable processes may be running on your Linux system. We’ll show you how to halt, continue, or kill tasks, and we’ll examine how to send the remnants of crashed programs to the happy hunting grounds.

What exactly is your Linux system doing right now? Which programs and processes are running in the background? Which application is accessing the CD-ROM drive? And how can you terminate a process if it won’t die gracefully? In this article, we'll explore some answers to these eternal questions. Listing Processes with ps

The ps program outputs a list of active processes. Running ps without specifying any options gives a list of applications running in the current shell. If you need more information, you can specify some of the tool’s impressive collection of options. As the manpage tells you, ps understands Unix parameters with a simple dash, BSD options without a dash, and GNU options with two dashes.

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Command Line: Process Control

    What is happening on your Linux machine? Various shell commands give you details about system processes and help you control them.

  • Command Line – Killing Processes

    Linux offers a variety of tools for shutting down systems and processes. We describe some important commands.

  • Isof

    Track down and expose intruders with the versatile admin tool lsof.

  • lsof

    In Linux, everything is a file – directories, devices, pipes – so lsof (list open files) reveals what's happening on your system.

  • Command Line: Mailx

    The simple mailx command-line mail client handles mail either interactively or via command-line options. Although it lacks the convenience of a GUI-based tool, mailx compares well in scripting.

comments powered by Disqus

Direct Download

Read full article as PDF: