4. Chrome OS Architecture
● Chrome os is built on Linux kernel
● It is 3 tier architecture system
○ Firmware
○ Linux kernel
○ Chromium and window manger
5. FIRMWARE
● It is a software that is embedded into hardware providing low
level control for device functionality
● Stored in rom,eeprom or flash memory
● Booting the os faster and more secure.
● To achieve this goal we are removing unnecessary components
and adding support for verifying each step in the boot process
Functionalities:
System recovery: the recovery firmware can re-install
chromium os in the event that the system has become
corrupt or compromised.
Verified boot: each time the system boots, chromium os
verifies that the firmware, kernel, and system image have not
been tampered with or become corrupt. This process starts
in the firmware.
Fast boot: we have improved boot performance by
removing a lot of complexity that is normally found in pc
firmware.
6. LINUX KERNAL
It is a computer program that manages input/output requests
from software, and translates them into data
processing instructions for the central processing unit and
other electronic components of a computer. The kernel
performs its tasks, such as system call interface (sci), process
management, virtual file system, memory management and
device driver and network stack.
7. SUBSYSTEMS OF LINUX
KERNAL
● System call interface
● Process management
● Virtual file system
● Memory management
● Device drivers
8. CHROMIUM AND WINDOW
MANAGER
● The window manager is a piece
of software responsible for
managing the different windows that
Appear on your screen.
● It controls :
● Placement of windows
● Drawing of the borders and scrollbars
● Ensures that the programs are shown well
● Window manager uses the X server which is the software responsible for drawing
everything on
● The screen. But the window manager is much more responsible for the decisions about
feel and
● Look of the windows on your screen.
9. CHROMIUM
● Chromium plays a critical role in Chrome OS, serving as the core web browsing
engine and providing the foundation for many features and functionalities within
the operating system. Here's a breakdown of Chromium's role in Chrome OS:
● Web Browsing Engine:
● Integration with Chrome OS
● Web App Platform
10. PROCESS MANAGEMENT
Creation of process
1. Request to Start a Task:
Imagine you want to open a new app or website on your Chromebook. You click on its icon
or type its name in the search bar, signaling to Chrome OS that you want to start a new task.
2. Initialization:
Chrome OS receives your request and begins the process of starting the task. It prepares
everything needed for the task to run smoothly.
3. Allocation of Resources:
Chrome OS allocates resources such as memory space, CPU time, and any necessary files or
data for the new task. Think of this like setting up a workspace for the task to operate in.
11. Process management
4.Launching the Process:
Once everything is ready, Chrome OS launches a new process for the task. A process is like a
container that holds all the instructions and data needed to carry out the task.
5.Task Execution:
The newly created process starts executing its instructions. For example, if you opened a web
browser, the process would start loading the webpage you requested.
6.Task Completion:
The process continues running until the task is completed or you close the app or website. Once
the task is finished, Chrome OS may terminate the process to free up resources for other tasks.
7.Cleanup:
After the process ends, Chrome OS cleans up any resources that were allocated to it. This
ensures that your Chromebook's resources are used efficiently and that there are no unnecessary
leftovers from completed tasks.
12. Process management
● In Chrome OS, processes are managed through a combination of the Linux kernel's capabilities
and Chrome-specific optimizations. Here's a breakdown of how processes are managed in
Chrome OS:
1. Linux Kernel Mechanisms:
● Chrome OS is built on the Linux kernel, which provides core functionalities for process
management, such as process creation, scheduling, memory management, and inter-process
communication (IPC).
● The Linux kernel handles the creation and termination of processes using system calls like ‘fork()’
and ‘exec()’
● It manages CPU scheduling to allocate processor time to different processes, prioritizing tasks
based on their importance and resource requirements.
13. Process management
• The kernel handles memory management, allocating and deallocating memory for processes, and
providing mechanisms like virtual memory to ensure each process has its own address space.
• Inter-process communication (IPC) mechanisms provided by the Linux kernel, such as pipes,
sockets, and signals, enable communication between processes.
Chrome-specific Optimizations:
Chrome OS incorporates optimizations specific to its environment to enhance process management:
• Sandboxing: Chrome OS uses sandboxing extensively to isolate processes from one another
and from the underlying system. Each Chrome tab, extension, and app runs within its own
sandboxed environment, preventing them from accessing unauthorized resources and
enhancing security.
14. UNIQUE FEATURES OF CHROMEOS IN PROCESS
MANAGEMENT:
● Lightweight Processes
● Single Process Model
● Cooperative Multitasking
● Priority Management
● Sandboxing
15. PROCESS
SYNCHRONIZATION
● In Chrome OS, process synchronization refers to coordinating and managing
concurrent processes running on the system. Chrome OS, like other operating
systems, uses various mechanisms for process synchronization to ensure proper
communication, coordination, and data consistency between processes.
● Here are some common mechanisms used for process synchronization in
Chrome OS:
16. ● Mutexes (Mutual Exclusion): Mutexes are used to ensure that only one
process can access a shared resource at a time. Processes acquire the mutex
before accessing the shared resource and release it when they're done. This
prevents multiple processes from concurrently modifying shared data, thus
avoiding conflicts and maintaining data integrity.
● Semaphores: Semaphores are a more generalized synchronization primitive
that can be used to control access to a shared resource by multiple processes.
They can be used to enforce limits on the number of processes accessing a
resource simultaneously or to signal events between processes.
● Condition Variables: Condition variables are synchronization primitives that
allow processes to wait for a certain condition to become true before
proceeding. They are often used in conjunction with mutexes to implement
more complex synchronization patterns, such as producer-consumer
relationships or reader-writer locks.
17. Message Passing: Message passing involves processes communicating with
each other by sending and receiving messages. Chrome OS may use message
passing mechanisms for inter-process communication, allowing processes to
synchronize their actions by exchanging data and signals.
Asynchronous Messaging with Mojo IPC:
● Chrome OS utilizes a messaging system called Mojo IPC (Inter-Process
Communication). This system enables processes to communicate
asynchronously, meaning they can send messages to each other without having
to wait for an immediate response.
● Mojo IPC is designed to be fast and secure. It facilitates efficient
communication between processes while maintaining strict security boundaries
to prevent unauthorized access or interference.
18. Key features of Mojo IPC include:
● Message Queuing: Messages sent between processes are queued up for
delivery, allowing processes to continue executing without waiting for a
response.
● Pipelining: Mojo IPC supports pipelining, where multiple messages can be
sent in parallel without blocking each other, further enhancing communication
efficiency.
● Error Handling: The system includes robust error handling mechanisms to
deal with communication failures or unexpected issues gracefully.
19. Smart Process Scheduling:
● Chrome OS employs a smart process scheduling algorithm to optimize the
utilization of system resources and enhance user experience.
This scheduling algorithm takes into account various factors such as:
● Available Resources: It considers the current availability of CPU, memory, and
other system resources to allocate them efficiently among running processes.
● User Activity: The algorithm monitors user interactions and prioritizes
processes accordingly to ensure responsiveness, especially for foreground
applications.
● Power Management: Chrome OS also considers power management goals,
such as minimizing battery consumption, by intelligently scheduling processes to
optimize energy efficiency.
20. Chrome OS uses a supervisor process called "init" to manage all of the other
processes on the system.
DEADLOCKS IN CHROMEOS:
• Tab synchronization: In Chrome OS, tabs can synchronize their state across
multiple devices. This synchronization can lead to deadlocks if one tab is
waiting for a resource that is locked by another tab on a different device.
• GPU resource contention: Chrome OS uses the GPU for tasks such as
hardware acceleration and video playback. If multiple processes are
competing for GPU resources, it can lead to deadlocks and system instability.
21. ● PREVENTION OF DEADLOCKS IN CHROMEOS:
Thread prioritization: Chrome OS assigns different priorities to different
threads based on their importance, allowing critical threads to execute first
and reducing the chances of deadlocks.
Graceful shutdown: When a process is terminated, Chrome OS ensures that
all resources used by the process are released in a controlled and orderly
manner, reducing the risk of deadlocks caused by resource conflicts.
22. CHROME OS SCHEDULING
● Chrome OS scheduling refers to the process by which the Chrome operating
system manages and prioritizes tasks and processes running on a device
23. SCHEDULING ALGORITHM
• Chrome OS uses a Preemptive priority-based scheduling algorithm
• Processes with higher priority levels are given preferential treatment
• Operating system assigns priority levels based on importance and resource
requirements
24. CGROUPS
• Chrome OS uses cgroups to group related processes together
• Cgroups help manage resource allocation and prevent monopolization of
system resources