Process ID file management for background services
The pid files contains the process id (a number) of a given program. For example, Apache HTTPD may write it's main process number to a pid file - which is a regular text file, nothing more than that - and later use the information there contained to stop itself. You can also use that information (just do a
cat filename.pid
) to kill the process yourself, usingecho filename.pid | xargs kill
.