๐Ÿš Shell

Computer Systems / Operating System

The shell is a user-level ๐Ÿ’ผ Process that reads in commands to execute; this is the terminal we use to run stuff. The shell keeps track of jobsโ€”commands started interactivelyโ€”that can either be in the foreground or background. Each job is associated with a process group.

Session

A session is a collection of process groups either attached to a terminal or not attached to any terminal (daemon's). Within a session, there are foreground and background processes.

Foreground jobs read from terminal input stdin and also receive signals from the keyboard. Background jobs can't read stdin and will receive a signal if it tries to do so. Both types of jobs can write to stdout.

Content by William Liang, written in Obsidian.
Thank you to all the educators who made these notes possible.