Handy for debugging and ascertaining which device drivers were installed and which system interrupts in use. The output of dmesg may, of course, be parsed with grep , sed , or awk from within a script. May also be invoked with the -k option, which kills those processes. This has interesting implications for system security, especially in scripts preventing unauthorized users from accessing system services. Job control commands, such as kill and renice act on the pid of a process, rather than its name.
Related commands are renice , snice , and skill .
If you use nohup within a script, consider coupling it with a wait to avoid creating an orphan or zombie process. The output of this command lends itself to parsing, using grep , awk or Perl . While not strictly necessary, a sync assures the sys admin or user that the data just changed will survive a sudden power failure. In the olden days, a sync sync was a useful precautionary measure before a system reboot. The init command is the parent of all processes.