week 4 - L1 - Linux Operating System Flashcards
The Linux OS comprise a number of elements. What are they?
Bootloader Daemons Shell Graphical Server Kernel Desktop Environment
Bootloader
- what is it?
- is it part of the kernel?
- Bootloader – software that manages the boot process of a computer
- (not part of the kernel)
o Ex the dual-boot in labs that make you choose between windows and linux)
Kernel
- Kernel – (lowest level) core of the operating system
o Manages the CPU, memory and peripheral devices
Daemons
- what are they?
- when do they start?
- Daemons – the background service (like printing or sound scheduling)
o They either start during the boot OR after you log in the desktop
Shell
- Shell – command line interface (CLI)
o (basically terminal where you write code)
Graphical Interface
- what does it display?
- Graphical Server – sub-system that displays the graphics on the monitor (Wayland or X)
o Basically display the graphics on the monitor
Desktop Environment
- Desktop Environment – user interface* such as GNOME, KDE, XFCE
Multi-tasking
- Linux and other Unix-like operating system have been designed from the ground up as complete time sharing systems, that is, as both multitasking and multi-user systems.
- A multitasking system: allows multiple processes to operate seemingly simultaneous without interfering with each other
Multiuser
- A multi-user system: allows multiple users to use the system at the same time, with each having the illusion they’re the only ones using it (they’re the sole user)
Linux layers
- what are the 3?
- what do each of them do?
- more about them:
- what time of control over CPU does the kernel have? what about the processes?
User Space
Kernel
Hardware
User space: Shell, GUI, Web Browser
Kernel: Memory Management, Process Management, Network stack, Device Drivers, System calls
Hardware: CPU, RAM, Hard drive, Network Card
Hardware
– CPU, memory, storage, network interfaces
Kernel
– Core of the OS responsible for managing processes, memory and device hardware
– unrestricted access to the CPU and memory
User space
- Consisting of processes (running programs) that the kernel manages
- restricted access to memory and safe CPU operations
Process
- what is it?
- what does it consist of?
- what does each process have? what do we use to identify it?
- who schedules the process to run on a CPU?
- what happens to the processes and CPU time? and what is it known as
An execution/instance of a program (task)
- is the basic unit of EXECUTION in a Linux OS
A process consists of the code and data (in memory) to run
A process has a PROCESS IDENTIFIER (PID)
The kernel schedules the process to run on a CPU
CPU time is distributed between running processes, which is known as scheduling
o Other processes may be swapped to swap space on persistent storage or suspended
what does the userspace contain?
what does the kernel contain?
what does the Hardware contain?
User Space:
- User Applications,
- GNU C library
Kernel Space:
- System call interfaces,
- Generic call interfaces,
- Architecture Dependent Kernel Code
Hardware:
- CPU
- Memory
user and kernel space
- what memory space does the process occupy? what about the kernel?
- what happens in the userspace?
- what must happen to the address space used by the kernel?
- how does the userspace communicate with the kernel?
- each process occupies its own virtual memory space
- the kernel occupies a single protected address space
- user space is where the processes are executed
- it also contains the GNU C library (glibc) shared by many processes
the address space used by the kernel must be protected from the applications that run in user space
userspace uses system calls to communicate with the kernel
the system call interface provides a means to perform function calls from user space into the kernel (i.e. read and write)
about the processing scheduling algorithm
- how is it?
- what about the code to switch processor contexts?
- what does the scheduler choose?
The scheduling algorithm is generic
The code to switch processor context is not generic, because each CPU architecture has its own registers
The scheduler chooses the next process to run and then calls the architecture-specific code to apply the context switch
what are the components of the kernel?
basically what we learned in he last weeks, the lecture titles
System call interface Memory management Process management Virtual file system Device drivers