3

Among the many components of a Linux system, I find myself confused about what exactly is the kernel or what is GNU's part. I understand some basic concepts of this, but where is the line between a shell and the Window Manager?

2 Answers 2

4

Kernel

The kernel manages resources. Resources include processor time, memory, and peripherals. It does this by directly communicating with the resources and exposing an interface to userspace.

Userspace Tools (sometimes includes GNU tools and utilities)

The Userspace Tools include basic utilities like ls, cat, dd, ln, mount, etc. They allow a user to work with resources that the kernel provides. Linux (as opposed to BSD, OSX, and other Unices) is the primary user of the GNU tools, but not even all Linux systems use these; an alternate set of tools for Linux is provided by Busybox.

Shell

The shell provides the environment that allows the user to use the Userspace Tools. Example shells include bash, ksn, zsh, and fish. They typically provide a prompt at which the user can enter commands that launch the userspace tools.

Window Manager

This is a much higher layer, there usually exists a display server, which is responsible for managing graphical, audio, and I/O resources, and providing an interface to higher-level tools. Usually, a display manager is the layer above the display server and can provide things like user login management, and session management. Above that is typically a window manager. The window manager provides regions in which applications can render their content, it also allows the user to interact with these regions by moving, resizing, and reordering them.

2

If you're using 'bash' as your shell, that's a GNU utility. The 'coreutils' package on your system contains GNU software, things like mv, ls, rm, etc.

The Kernel is not something you interact with directly, but through other software on your system. To be very general in definition, a kernel is provides a means for software to interact with the hardware on your system, by reading in your key presses and mouse movement, reading and writing data to your disks, and scheduling and performing the computation from software running on your computer. There are a lot of details I'm ignoring/glossing over, you might benefit from reading the Kernel Wikipedia page.

Your window manager is most likely not GNU software, but from other software projects (Gnome, KDE, XFCE, etc). However, they all rely on GNU software to run, using the GNU C Library (glibc) and the GNU Compiler collection (gcc) for example. Also, much of the software on your system is licensed with the GNU General Public License, or the GPL, so you're benefiting from GNU's license.

You must log in to answer this question.