Linux Survival
Search
Primary Menu
Skip to content
Home
Blog
Testimonials
Linux Links
Command List
Contact
Search for:
Linux Survival
Just the other day, your friend Harry Hacker gave you a copy of his brand-new program called "rogue". A couple of minutes ago, you tried running it for the first time, and instantly regretted doing so. It is now clear that this program is out of control and must be terminated. The command used to examine running programs (or "processes", in Linux lingo) is "ps", which stands for "process status". The "ps" command has a ton of options, but you do not need to know most of them. To get a detailed list of all processes, type ps aux You might be wondering if there is a typo in the command above because it's missing a '-' before "aux", but that's actually how you're supposed to type this command. On many systems, it will work if you use "ps -aux", but on some it won't, so you should get in the habit of using "ps aux" instead. To make things even more confusing, there are some "ps" options that do require a '-' and even some that require a "--". If you would like more details, have a look at the man page. As you can see, this command gives a large amount of difficult-to-read output, but we will show you how to make it more user-friendly in a couple of pages. This output isn't actually as bad as it looks. Here is a summary of the columns: USER - the process owner PID - the process ID (you will need this) START - the date or time when this process started TIME - the amount of CPU time used by this process COMMAND - the command that started the process As usual, we have left out a number of columns which are of no interest to most users. We have also left out the vast majority of processes that you would normally see (thus the "..."). A typical system would show 50 or 100 different processes. The first three processes in our example were started by someone called "root". You can think of "root" as the User ID of the Linux system itself. When a machine is booted up, "root" starts a number of essential processes. You can tell by the PID's of "init", "[keventd]", and "[ksoftirqd_CPU0]" that they were the first three processes started when the machine was booted. Click the right arrow.
Page 60
Where learning Linux is easy
Module 1 Introduction
Directory Structure
List Directory
View File Contents
Create Directory
Move and Rename File
Change Directory
Get Current Location
Quiz 1
End of Module 1
Module 2 Introduction
Pathnames
Copy File
Remove File
Remove Directory
File Security
Change File Permissions
Wildcards
Groups Memberships
Quiz 2
End of Module 2
Module 3 Introduction
Home Directories
Manual Pages
User Information
Find File
Concatenate Files
Redirect Output
Print
Print Job Status
Cancel Print Job
Quiz 3
End of Module 3
Module 4 Introduction
Copy Tree
Disk Space
Remove Tree
Process Status
Pipe Output
Pattern Matching
Kill Process
Quiz 4
Conclusion