Introduction to Linux Systems Administration
To kill process number 593 in an almost guaranteed way, type the following:
[root@ford /root]# kill -9 593
To send the init program (which is always process ID 1) the HUP signal, type the
[root@ford /root]# kill -1 1
The capability to terminate a process is obviously a very powerful one. The developers
of the kill command realized this and made sure that security precautions existed so that users can
kill only those processes they have permission to kill. For example, nonroot users can send signals
only to their own processes. If a nonroot user attempts to send signals to processes that she does
not own, the system returns error messages. On the other hand, the root user may send signals to
all processes in the system. This means that when using the kill command, the root user needs to
exercise great care to avoid accidentally killing the wrong process!
If this book were devoted to the commands available in your Linux system, the tools
discussed in this section would each fit into specific categories. But since this overview
is focused on only the most important tools for day-to-day administrative chores, the
following tools are lumped together under "miscellaneous." However, even though
this section declines to classify them under their own specific categories, that doesn't
mean the tools are not important!
uname: Show the System Name
The uname program allows you to learn some details about a system. This tool is
often helpful when you've managed to log in remotely to a dozen different computers
and have lost track of where you are. This tool is also helpful for script writers since
it allows them to change the path of a script based on the system information. The
command-line parameters for uname are listed in Table 21-12.
Print the machine hardware type (for example, i686 for Pentium Pro
and better architectures).
Print the machine's hostname.
Print the operating system's release name.
Print the operating system's name.
Print the operating system's version.
Print all of the preceding information.
Common uname Command Options