OS Structures, OS Services, User OS Interface, System Calls, Types of System Calls, System Programs, OS Design and Implementation, OS Debugging, OS Generation, System Boot.
To provide essential functionalities for user applications and system management.
A mechanism that allows user programs to request services from the operating system.
Different categories of system calls that provide various functionalities, such as process control, file management, and device management.
They perform tasks that support the operation of the system and user applications.
The process of creating an operating system architecture and coding its components.
APIs provide a set of functions that use system calls, which are implemented in the C library.
APIs offer a higher-level, easier-to-use interface for developers compared to direct system calls.
To manage resources for multiple users or jobs running concurrently.
System calls that allow user programs to request services from the kernel.
Vim.
They are not well separated.
File-system manipulation.
Single memory space.
Communication.
To identify and handle errors.
To provide necessary information to the system call for execution.
CLI, GUI, and Batch.
Java, using the Android API.
open() - to open the source file.
printf()
'top' program or Windows Task Manager.
Interprocess communication and Network communication.
To create, delete, copy, rename, print, dump, list, and manipulate files and directories.
Performance, logging, and debugging information.
Functions that allow user applications to request services from the operating system.
Easier updates and maintenance.
Code = 0.
read() - to read data from the opened source file.
It is unsafe and difficult to enhance.
To improve performance by removing bottlenecks.
A core set of libraries and the Dalvik VM.
It allocates and manages memory for applications and processes.
Easier debugging and maintenance.
Creating connections among processes and users.
Libraries for webkit, SQLite, multimedia, and a smaller libc.
Portable Operating System Interface for Unix.
write() - to write the read data into the destination file.
To allow applications to communicate with the operating system.
Changes file owner and group.
Functions provided by the operating system to facilitate user and application interactions.
Mach and mk-Linux.
It is very expandable and does not require modification to add commands.
File management.
It stores configuration information.
It can be difficult to define layers.
Application Programming Interface.
Individual processes.
int chown(const char *path, uid_t owner, gid_t group);
Managing hardware resources.
By providing a user-friendly interface and managing system resources efficiently.
Services that launch at boot time and run in the background.
To observe specific events.
Less efficient and difficult to define layers.
Single-tasking.
They manage hardware resources and provide a user interface.
An API defined by Microsoft for Windows UI, I/O, disk, and more.
A suite of software to run applications.
It ensures that the system call receives the correct data to perform its function.
No, it is not a system call.
It gives control back to the OS, either normally or abnormally (indicating an error).
Application programmers.
Memory-usage statistics.
It does not understand the command, only the syntax.
To provide convenience for program development and execution.
To check the integrity of the disk.
They facilitate communications between programs and users.
Function calls to request OS services.
stat, top, record, report, annotate, sched, list.
Get/set time, date, or system data.
Per-process tracing.
Send messages, browse web pages, send email, remote login, FTP.
Date, time, available memory, disk space, and number of users.
Most Unix-based systems, including Linux and macOS.
Compiler, linker, interpreter, library, loader.
$ man -k chown
Simplicity.
A shell that understands all commands.
The OS should be reliable, error-free, and efficient.
Hardware.
User mode and kernel mode.
File manipulation, status information, programming language support, loading and execution, communications, and background services.
fork().
Command-line Interface.
The OS provides services for program execution.
An error code.
I/O operations.
It closes an open file.
(1) Log files error info (2) Core dump file captures memory of the process.
It combines monolithic and microkernel architectures for subsystem 'personalities'.
It creates a new file.
They are compiled to Java bytecode and translated to executable code for the Dalvik VM.
CPU cycles, main memory, file storage, and I/O devices.
TCP/IP protocol stack.
Many are mapped to the host OS’s API.
Components and services.
What will be done and what is allowed (parameterizable).
Statistics for current processes.
APIs might not need to make a system call, which can be more efficient.
I/O usage statistics for disks.
APIs provide a user-friendly interface for applications to interact with system calls, which are the actual requests made to the OS for services.
APIs abstract the complexity of system calls, providing a simpler and more intuitive way for developers to access OS functionalities.
It is monolithic for performance but modular.
A collection of performance tools.
On booting.
Configure, read/write, connect/disconnect devices.
No, no process is created.
Less code runs in kernel mode, making it more secure.
Mobile phones with a keyboard and no touch screen.
Captures the memory of the process for debugging.
To monitor and tune system performance.
The number of bytes read, 0 for EOF, or -1 if there is an error.
Instruction trace for statistical trends.
An OS architecture that minimizes the kernel's functionality, running most services in user space.
No, many math APIs do not need system calls.
An abstract computing machine that enables a computer to run Java programs.
QuickTime, OpenGL, cloud, database.
2
24
It has a minimal structure and is not divided into modules.
Message passing and shared memory.
Message-passing and shared-memory.
Using a parameter table.
Its modular approach.
write()
The OS should be reliable, safe, and fast.
Increased modularity and flexibility, allowing for easier updates and maintenance.
The OS is divided into N layers (0..N-1).
They are designed for convenience.
They terminate after performing their tasks.
They provide programming language support, loading, and execution.
Read, write, create, delete files and directories; search them, list file info, manage permissions.
It waits for the process to terminate or continues with user commands.
csh, bash.
Debugging facilities to help identify and fix errors.
Remote Procedure Call.
Create, delete, open, close, read, write, reposition, get and set file attributes.
Send and receive messages.
Linux.
It started out as a microkernel.
They are dynamically loadable modules.
It opens an existing file for reading or writing.
Loadable kernel modules (LKM).
Wait for time, event, signal event.
Ahead-of-time (AOT) compilation to native code.
No need to recompile the kernel.
Solaris, Linux, Windows.
6
Means of computing and displaying measures of system behavior.
Services provided by the OS to facilitate user and application interactions.
By controlling access to resources and protecting data.
Via a table or a specific data structure.
Less efficient.
In registers, as defined by the ISA.
The OS should be easy to use and learn.
Inter-process communication, basic scheduling, and low-level address space management.
It requires modification of the shell to add commands.
Statistics for network interfaces.
A Unix variant.
The user's choice of shell is invoked (e.g., bash, tcsh, ksh).
Services that run in the background to support other applications.
Abort, create, terminate process, allocate/free memory.
Program execution.
Graphical User Interface.
#include <unistd.h>
Send/receive data messages.
It overwrites all but the kernel.
To read data from a file.
To run user programs.
Changes to support power management.
By managing access to resources and data.
Get and set process attributes.
It defines the executable program format.
Error dump, single-step for debug.
Methods for passing parameters, such as stack or register.
QuickTime.
12
Keeping track of which users use how much and what kinds of computer resources.
UI, I/O, and other functionalities for the Java virtual machine (JVM).
It allows for flexibility and scalability in system design.
A minimalistic kernel that provides only the essential services needed for the operating system.
To move as much functionality from the kernel into user space.
Through message passing.
#include <unistd.h>
System calls act as the interface between user applications and the operating system, allowing programs to request services from the OS.
The kernel for macOS and iOS.
GNU source-level debugger.
Kernel extensions that allow for dynamic loading of drivers.
An entry point into the OS; it acts as an API.
int open(const char *path, int flags);
To address performance, security, and usability needs.
Search contents and transform text.
Direct manipulation and visual/audio feedback.
The shell is reloaded.
The Open Handset Alliance.
Counters, monitors, and trace tools.
Google Mobile Services.
Debugging systems for higher-level and machine language.
It is loaded as needed and can be unloaded.
Advantages of microkernel and layered architecture.
No need for message passing.
OpenGL.
21
open() - to create or open the destination file.
close() - to close both the source and destination files.
Store parameter values in a table in memory and pass the table’s address in a register.
printf() calls write(), which is an actual system call.
How to do it (implementation).
A microkernel has a smaller codebase and runs most services in user space, while a monolithic kernel includes many services in kernel space.
It is easier for extending and porting applications.
It is smaller but has a heavier weight per command.
Multitasking.
strace.
To manage device drivers in macOS and iOS.
Shared memory and message passing.
To open a file.
Process, file, or device attributes.
In 2005.
int fd, void *buf, size_t count.
Loading and execution.
Compilers, assemblers, debuggers (gdb), and interpreters (python).
Loading programs into memory.
Managing remote device connections.
The process of identifying and fixing errors in the operating system.
Application Binary Interface.
Google Play and Google Mobile Services.
Cocoa.
Sizes and endianness.
1
23
Protection ensures controlled access to system resources, while security involves user authentication and defending against invalid access attempts.
stdio library
It loads a program into memory to run.
To access the BSD System Calls Manual for chown.
The OS should be easy to design, implement, and maintain.
A shell that invokes executable files.
System services or system utilities.
They define most users’ view of the operating system.
It is difficult to scale complexity.
A microkernel but with kexts.
By command line, mouse click, or finger poke.
Scheduling, IPC (Inter-Process Communication), and memory management.
They are a mix of different models.
Date/time, location, proximity, authentication service.
Communications system calls.
int close(int fd);
CLI, file system, networking, and library interface.
Crash dump file containing kernel memory.
It removes an existing file.
Recorded activities for analysis.
The brk() system call, which is called by malloc() and free().
Open source.
USB driver.
In the header file /usr/include/sys/syscall.h.
It resolves addresses of all symbols.
5
59
Applications written in a specific language or particular calling convention.
By maintaining system-call numbers and providing a calling interface.
User code pushes the parameters onto the stack, and the OS pops them off the stack on return.
Improved resource management.
The same standard API (e.g., POSIX) across different platforms.
No, it is not always so separated but is desirable as good practice.
Per-process and system-wide.
In one address space.
A function of system programs that manages the execution of processes.
No, they are not typically considered part of the OS.
System programs serve as a layer above system calls, while application programs utilize these services.
Detecting errors in CPU and memory hardware, I/O devices, and user programs.
To read data from a file descriptor.
To represent data objects or controls.
A minimal core with separate address spaces for each service.
A structure that is dynamically loadable and operates in the same address space.
Distributing system resources among processes.
To write data to a file.
Generally done as assembly language instructions.
Mixed License: open source for Android core and proprietary for Google Play and Google Mobile Services.
It writes data to an open file.
To emulate hardware and run multiple OS instances on a single physical machine.
CocoaTouch.
A monolithic Linux kernel.
7
APIs provide a set of functions that map to system calls for application use.
File or I/O device operations.
It allows maximum flexibility if policy decisions need to be changed later.
It may introduce overhead due to increased communication between user space and kernel space.
User interface.
They are tightly coupled with a large number of functions for one level.
The POSIX API is an example that provides a standard interface for system calls in Unix-like operating systems.
exec().
User interface.
Traces network packets.
Linker and loader.
A structure with two levels and no internal structure.
Linux and Solaris.
Gesture-based, Brain-Computer Interface (BCI), Voice.
Status information.
It has a straightforward structure with minimal layers.
It includes multiple layers and components for enhanced functionality.
It reads data from an open file.
An architecture that allows components to be added or removed as needed.
Traps are used to make explicit requests to the kernel.
Aqua.
SQLite, OpenGL, WebKit, Surface Manager, SSL, Media Framework.
20
They enable user programs to perform operations like file manipulation, process control, and communication.
The owner ID and group ID of a file.
sprintf() - it just performs formatting.
I/O Manager, Graphics Subsystems, Network Drivers, Device Drivers.
Only the services provided by lower layers.
A service that records errors for troubleshooting.
Windows is also monolithic but has become more modular.
To allow users to type commands as text and execute code.
By invoking the shell.
Easier for extending and porting to new architecture.
Finding and fixing errors.
Request, release device, attach, detach devices, read, write, reposition, get device attributes, set device attributes.
Create and gain access to memory regions.
ssize_t read(int fd, void *buf, size_t count);
For performance reasons.
ssize_t write(int fd, const void *buf, size_t count);
The process of creating a customized version of an operating system for specific hardware.
The virtual machine used in Android for executing applications.
Instruction Set Architecture, which can include native or bytecode.
Get and set permissions, allow and deny user access.
It loads the linked image into memory for execution.
10
Lower layers are independent of upper layers.
Easier debugging and maintenance.
They allow applications to perform operations like file manipulation, process control, and communication with hardware.
Between processes on the same host or between hosts over a network.
Create, delete, open, close, read, write file.
File search and edit.
Mouse, keyboard, display, and now touch screens.
System-wide tracing.
POSIX system calls.
The file descriptor.
A pointer to the data buffer to store read data.
The maximum number of bytes to read.
To link different program modules together.
Create, terminate, end, abort, load, execute.
Core components and LKM interfaces.
Allocate and free memory.
Locks for shared data.
It is similar but more flexible.
4
38
Less efficient than a monolithic kernel due to more message passing for user-to-kernel communication.
A total redesign to support touch screens.
A combination of monolithic or microkernel structures with modular components.
To track system usage and resource consumption.
Android, which uses the Linux kernel.
An architecture that organizes the OS into layers, each with specific functions.
A set of library calls, which may or may not include system calls.
Darwin.
The standard C library.
It refers to the structure of application frameworks, though they can be bypassed.
9
Darwin (macOS, iOS) with Mach microkernel and BSD Unix.
They serve as the OS's interface to user code, allowing explicit requests to the kernel.
Process Control.
It closes an open file.
The sequence of events that occurs when a computer is powered on, leading to the loading of the operating system.
ELF, COFF, Mach-O, EXE, PE.
A binary that contains multiple architectures for compatibility.
To provide a standard interface for hardware components.
3
37
Manage memory for larger programs by loading only necessary parts.
Java.
It changes the current position in a file.
Java Native Interface.
It is optimized for mobile devices and bypasses the GPL.
It contains system call numbers and is automatically generated.
22
Beyond simple but not fully layered.
To use the least space.