Background Processes

Many times you will want something to run on your Unix system but you won't want to see or use it while it is running. Having this process in the foreground will only cause you to waste time watching something that could be taking place without your input. In this situation, you would want to run a background process. Whereas a foreground process remains in the foreground and usually takes up many of the resources available on your system, a background process can run largely without your intervention.

Making a command run in the background is simple; you simply add an ampersand (&) to the end of the line containing the command. For example, you could use & to run the cron or at commands in the background. The cron command is used for scheduling jobs to be executed regularly after a designated period of time. The at command is for executing commands once at a single specified time. These commands will be discussed in greater depth later in the lesson.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.189.170.206