In Linux, what is the difference between a foreground job and a background job?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
In a foreground job, all of your input is directed to the process’s
stdin(including theSIGINTthat is generated when you pressCTRL-C, and that’s why you can still kill the process if it’s in the foreground).In a background job your input is directed to the shell process instead, and that is why you see the shell prompt and you can execute commands.