Operating System Note [ काठमाडौंउपत्यकाखानेपानी लिमिटेड प्राविधिक सेवा, सुचनाप्रविधिसमूह, ५ तह, ओभरसियर(IT) ] Kathmandu Upatyaka Khanepani Limited (KUKL)

Anil Pandit
0

 

 

3.1. Introduction, Types and Functions of operating systems

An Operating System (OS) is a software that acts as an intermediary between computer hardware and the computer user. Its primary role is to manage and coordinate the resources of the computer, such as the CPU, memory, and storage devices, to ensure efficient operation and usability for running applications.

Functions of an Operating System:

  1. Process Management: The OS handles the creation, scheduling, and termination of processes. It ensures that multiple applications run smoothly without conflicts.

  2. Memory Management: It allocates and deallocates memory spaces as required by different programs. It also manages virtual memory, ensuring that applications don’t exceed physical memory limits.

  3. File System Management: The OS controls how data is stored, organized, and accessed on storage devices.

  4. Device Management: It manages hardware devices such as printers, disk drives, and network interfaces. This ensures proper communication between hardware and software.

  5. Security and Access Control: An OS ensures that unauthorized users do not access the system. It manages user authentication and system permissions.

  6. User Interface (UI): The OS provides a UI for users to interact with the system, commonly through Graphical User Interfaces (GUIs) or Command-Line Interfaces (CLIs).

  7. Error Detection and Handling: The OS monitors the system for errors and provides mechanisms to handle or recover from them.

Types of Operating Systems:

  1. Batch Operating System:
    • Jobs are grouped and processed in batches without user interaction.
    • Suitable for large jobs that require significant processing time.

  2. Time-Sharing Operating System:
    • Allows multiple users to use the computer simultaneously by sharing time slices of CPU resources.
    • Example: UNIX, Linux.

  3. Distributed Operating System:
    • Manages a group of independent computers and makes them appear as a single system.
    • Tasks are distributed across different machines to optimize performance.

  4. Real-Time Operating System (RTOS):
    • Provides immediate processing of tasks to meet strict timing constraints, often used in embedded systems.
    • Example: RTLinux, VxWorks.

  5. Multitasking/Multiprogramming Operating System:
    • Allows multiple programs to run at the same time by efficiently allocating system resources.
    • Example: Windows, macOS.

  6. Network Operating System (NOS):
    • Provides networking capabilities, allowing multiple systems to communicate and share resources.
    • Example: Novell NetWare, Windows Server.

 

3.2 Basic Components of the Operating System

An Operating System (OS) is system software that manages computer hardware and software resources and provides services for computer programs. It acts as an interface between the user and the hardware.

Basic components of an operating system:

1. Kernel

·         Core part of the OS.

·         Manages system resources like CPU, memory, and devices.

·         Controls low-level operations.

·         Types of kernels: Monolithic, Microkernel, Hybrid.

Functions:

·         Process management

·         Memory management

·         Device management

·         System calls handling

2. Process Management

·         Handles creation, scheduling, and termination of processes.

·         Ensures proper synchronization and communication between processes.

·         Manages CPU allocation for multiple tasks.

3. Memory Management

·         Manages the system’s primary memory (RAM).

·         Allocates and deallocates memory space to processes.

·         Keeps track of each byte of memory.

Includes:

·         Virtual memory

·         Paging and segmentation

·         Memory protection

4. File System Management

·         Manages files on storage devices.

·         Handles file creation, deletion, reading, writing, and permission.

·         Organizes files into directories/folders.

Supports:

·         File naming, access control, backup and recovery.

5. Device Management (I/O Management)

·         Controls hardware devices like keyboards, printers, and hard drives.

·         Uses device drivers to communicate with hardware.

·         Handles input/output operations and buffering.

6. User Interface (UI)

·         Provides a way for users to interact with the system.

·         Types:

o    Command-Line Interface (CLI): Text-based (e.g., MS-DOS, Linux terminal)

o    Graphical User Interface (GUI): Uses windows, icons, menus (e.g., Windows, macOS)

7. Security and Access Control

·         Protects data and system from unauthorized access.

·         Provides authentication (login, passwords) and permission control.

8. Networking Component

·         Manages data exchange between computers.

·         Supports network protocols (TCP/IP).

·         Allows sharing of files and printers over a network.

3.3 Concept of File, Folder, Shortcut, Desktop, etc.

These are basic elements of a graphical user interface (GUI)-based Operating System like Windows, macOS, or Linux

1. File

·         A file is a collection of related data or information stored in a digital format.

·         It can contain text, images, videos, audio, programs, etc.

·         Every file has a name and a file extension (e.g., .txt, .jpg, .exe, .docx).

·         Examples:

o    notes.txt (text file)

o    image.jpg (image file)

o    report.pdf (PDF document)

2. Folder (or Directory)

·         A folder is a container used to organize files and other folders.

·         Helps keep the system organized and easy to navigate.

·         You can create subfolders (folders inside folders).

·         Example:
Documents folder may contain files like resume.docx, project.pdf.

3. Shortcut

·         A shortcut is a link that points to a file, folder, or application.

·         It allows quick access without opening the original location.

·         Identified by a small arrow icon on it (in Windows).

·         Example: A shortcut to MS Word on the desktop.

4. Desktop

·         The desktop is the main screen area that you see after starting the computer.

·         It displays icons for files, folders, shortcuts, and system tools like Recycle Bin.

·         It acts as a workspace for users.

·         Background image is called wallpaper.

5. Icon

·         A small graphical symbol representing a program, file, folder, or shortcut.

·         Clicking an icon opens or executes it.

·         Examples: Recycle Bin icon, This PC icon, Chrome browser icon.

6. Taskbar (in Windows OS)

·         Located at the bottom of the screen.

·         Shows open applications and system notifications.

·         Contains Start Menu, Quick Launch bar, and System Tray.

7. Recycle Bin

·         A special folder on the desktop that temporarily stores deleted files/folders.

·         Allows users to recover accidentally deleted files.

·         Files can be permanently deleted by emptying the Recycle Bin.

 

3.4 Introduction to the Windows Family of Products and Unix Family of Products

What is Windows?

·         Windows is a popular operating system developed by Microsoft.

·         It is GUI-based (Graphical User Interface) and user-friendly.

·         Widely used in personal computers, laptops, and some servers.

Features:

·         Easy-to-use interface with icons, taskbar, and start menu.

·         Supports multitasking and multiple user accounts.

·         Regular security and feature updates.

·         Broad compatibility with software and hardware.

Popular Versions of Windows:

Version

Release Year

Key Features

Windows 95

1995

Start menu introduced, Plug and Play support

Windows XP

2001

Stable, user-friendly, improved multimedia

Windows 7

2009

Enhanced UI, performance improvements

Windows 8/8.1

2012/2013

Touch screen support, new Start screen

Windows 10

2015

Universal apps, Cortana, frequent updates

Windows 11

2021

New design, better performance, Android app support

 

Common Uses of Windows OS:

·         Home and office computing

·         Gaming

·         Business and enterprise systems

·         Education

What is Unix?

·         Unix is a multi-user, multitasking operating system originally developed in the 1970s at AT&T Bell Labs.

·         Known for its stability, security, and efficiency.

·         Mostly used in servers, workstations, and mainframes.

Features:

·         Command-line interface (CLI) based (some with GUI).

·         Multi-user and multi-tasking support.

·         Strong file and process management.

·         Highly secure and reliable.

Popular Unix and Unix-like Systems:

Unix Product

Type

Used For

IBM AIX

Proprietary

Enterprise servers

HP-UX

Proprietary

HP enterprise systems

Solaris (Oracle)

Proprietary

High-end servers

BSD (FreeBSD, OpenBSD)

Open-source

Networking, firewalls, and servers

macOS (by Apple)

Unix-based

Desktop and laptop OS for Apple devices

Linux

Unix-like

Servers, desktops, embedded systems (free)

Note: Linux is not Unix, but it is Unix-like and inspired by Unix.

Common Uses of Unix OS:

·         Web servers and cloud computing

·         Supercomputers

·         Academic and scientific research

·         Network management

Comparison: Windows vs Unix

Aspect

Windows

Unix/Unix-like

User Interface

GUI-based

CLI-based (some GUI in variants)

Usage

Home, Office, Gaming

Servers, Scientific, Developers

Security

Moderate

High

Cost

Mostly paid (licensed)

Many are free (Linux, BSD)

Customization

Limited

Highly customizable

Popularity

Popular in desktop/laptop users

Popular in servers and networks

 

 

3.5 Installation, Backup, Recovery, and Optimization of Operating System

Understanding how to manage an operating system is essential for maintaining system performance, security, and data safety. Below are the concepts in detail:

1. Installation of Operating System

What is it?

·         The process of setting up an operating system (like Windows, Linux, etc.) on a computer.

Steps to Install an OS:

1.      Insert installation media (DVD, USB, or ISO file).

2.      Boot the computer from the installation media.

3.      Select language, time, and keyboard settings.

4.      Choose "Install Now".

5.      Select the installation type (clean or upgrade).

6.      Choose disk/partition where OS will be installed.

7.      Follow on-screen instructions to complete setup.

8.      Reboot the system after installation.

Types of Installation:

·         Clean installation – Removes everything and installs fresh OS.

·         Upgrade installation – Keeps files and upgrades to a new version.

·         Custom installation – Allows partitioning and advanced setup.


2. Backup of Operating System

What is Backup?

·         A backup is a copy of files, system settings, or entire OS stored separately to restore data in case of failure.

Types of Backup:

·         Full backup: Copies everything (files + system).

·         Incremental backup: Copies only changed files since the last backup.

·         System image backup: Copies the full OS setup including programs and settings.

Backup Tools:

·         Windows: File History, Backup and Restore, System Image.

·         Linux: rsync, tar, Timeshift.

·         Third-party: Acronis, Macrium Reflect, EaseUS, etc.

3. Recovery of Operating System

What is Recovery?

·         The process of restoring the OS to a working state after failure, corruption, or malware attack.

Recovery Methods:

·         System Restore: Reverts the system to an earlier state without deleting files.

·         System Image Recovery: Restores the whole system from a saved image.

·         Reset or Refresh (Windows): Reinstalls the OS while keeping or removing files.

·         Recovery Drive/Partition: Bootable tool to repair or reinstall the OS.

4. Optimization of Operating System

What is Optimization?

·         Techniques used to improve the performance and speed of the operating system.

Ways to Optimize an OS:

For Windows:

·         Uninstall unused programs.

·         Disable startup programs (via Task Manager).

·         Use Disk Cleanup and Defragmentation.

·         Keep OS and drivers updated.

·         Increase virtual memory.

·         Use antivirus to remove malware.

For Linux:

·         Remove unnecessary services and daemons.

·         Clean up log files and unused packages.

·         Manage startup applications.

·         Use lightweight desktop environments for low-end PCs.

3.6 Managing Information Storage, Disks, and Partitions

Managing storage is one of the essential tasks of an operating system. It involves organizing data on physical devices like hard drives (HDDs), solid-state drives (SSDs), and removable storage, and dividing them into logical sections called partitions.

1. Storage Management

·         Refers to handling how data is stored, retrieved, and organized on storage media.

·         Ensures efficient use of storage space and data integrity.

·         Handles file saving, editing, deletion, and access control.

Functions:

·         Tracks free and used storage space.

·         Handles read/write operations.

·         Maintains directory structure (e.g., folders and files).

·         Ensures data security and reliability.

2. Disk Management

·         Deals with the configuration and maintenance of physical storage devices.

·         Operating systems use disk management tools to:

o    Format disks

o    Create or delete partitions

o    Assign drive letters

o    Monitor disk health

o    Defragment hard drives (for HDDs)

Examples of Disk Management Tools:

·         Windows: Disk Management utility (diskmgmt.msc)

·         Linux: fdisk, parted, lsblk, gparted

·         macOS: Disk Utility

3. Partitioning

·         Partitioning is the process of dividing a disk into separate sections to organize data better or install multiple operating systems.

Types of Partitions:

1.      Primary Partition: Can contain bootable OS; max 4 per disk (in MBR).

2.      Extended Partition: Used to overcome the limit of 4 partitions.

3.      Logical Partition: Created within an extended partition.

Partition Table Types:

·         MBR (Master Boot Record): Older standard, supports up to 2TB and 4 primary partitions.

·         GPT (GUID Partition Table): Newer, supports larger disks and more partitions.

4. File System

·         After partitioning, each partition is formatted with a file system which defines how data is stored and accessed.

Common File Systems:

·         Windows: NTFS, FAT32, exFAT

·         Linux: ext4, XFS, Btrfs

·         macOS: APFS, HFS+

5. Mounting (in Linux/Unix)

·         In Unix-like systems, partitions are "mounted" to directories.

·         Example: /home, /var may be separate partitions.

·         Mounting allows users to access the contents of a partition.

6. Volume Management

·         Logical Volume Managers (LVM) in Linux allow flexible resizing and management of disk space.

·         Volumes can span across multiple disks, offering better performance and management.

7. Disk Optimization & Maintenance

·         Defragmentation (for HDDs): Rearranges fragmented data to improve speed.

·         Disk Cleanup: Removes temporary and unnecessary files.

·         S.M.A.R.T. Monitoring: Checks disk health to predict failures.

3.7 Managing Directory Services, Users, Groups, and Permissions

Managing users, groups, and permissions is an essential part of an operating system's security and resource management. Directory services help to organize and control access in large networks.

1. Directory Service

·         A directory service is a centralized database that stores information about users, computers, groups, and other resources in a network.

·         Helps administrators manage access, authentication, and policies.

Examples of Directory Services:

·         Active Directory (AD) – by Microsoft (used in Windows Server)

·         LDAP (Lightweight Directory Access Protocol) – open standard

·         OpenLDAP, NIS, FreeIPA – Linux-based systems

Functions:

·         Stores user and group details.

·         Supports login authentication.

·         Controls access to shared resources (files, printers).

·         Centralizes user management in a domain.

2. User Management

·         Users are individual accounts that represent people or services accessing the system.

·         Each user has:

o    Username and password

o    Home directory

o    Unique ID (UID)

Types of Users:

·         Administrator (Root in Linux): Full control over system.

·         Standard User: Limited access.

·         Guest User: Temporary, minimal access.

User Management Tools:

·         Windows: User Accounts, lusrmgr.msc, net user

·         Linux: adduser, useradd, passwd, id, usermod

3. Group Management

·         A group is a collection of users.

·         Used to simplify permission management by assigning access rights to a group instead of individual users.

Types of Groups:

·         Windows:

o    Administrators, Users, Guests

·         Linux:

o    Primary Group: Linked to a user.

o    Secondary Group: For additional permissions.

Group Management Tools:

·         Windows: Local Users and Groups, net localgroup

·         Linux: groupadd, gpasswd, usermod -aG

4. Permissions Management

·         Controls who can access what and what actions they can perform (Read, Write, Execute).

Windows Permissions:

·         NTFS permissions:

o    Read

o    Write

o    Modify

o    Full Control

Linux Permissions:

·         Permissions are set for:

o    User (u) – owner

o    Group (g) – group members

o    Others (o) – everyone else

Permission Types:

·         r – read

·         w – write

·         x – execute

Permission Representation:

·         Symbolic: rwxr-xr--

·         Numeric: chmod 755 filename

Permission Commands:

·         chmod – change permission

·         chown – change owner

·         chgrp – change group

3.8 Managing Network Printing

Network printing allows multiple computers or users on the same network to share and use a single printer. This helps in reducing cost and improving efficiency, especially in office environments.

1. What is Network Printing?

·         Network printing means connecting a printer to a network so that it can be accessed by multiple users/devices.

·         Can be achieved via wired (Ethernet) or wireless (Wi-Fi) connections.

2. Types of Network Printers

1.      Direct Network Printer

o    Has a built-in network card (RJ-45/Ethernet or Wi-Fi).

o    Connects directly to the network using an IP address.

2.      Shared Printer

o    Connected to a host computer.

o    Shared with other users through that computer.

3.      Print Server-based Printer

o    Printer is connected to a print server which manages printing jobs.

o    Common in large organizations.

3. Components Involved

·         Printer – hardware device

·         Print Server – manages and queues print jobs

·         Printer Driver – software to communicate with printer

·         Client Computers – systems that send print jobs

·         Network – enables communication between printer and clients

4. Managing Network Printing (Tasks)

a. Installing the Printer

·         Windows:

o    Go to Settings > Devices > Printers & scanners > Add a printer

o    Select "Network Printer" or input IP address

·         Linux:

o    Use CUPS (Common Unix Printing System)

o    Access via browser: http://localhost:631

o    Add a printer and install drivers

b. Sharing a Printer

·         Enable printer sharing on the host system.

·         Assign a share name.

·         Ensure both devices are on the same network/workgroup.

c. Assigning Permissions

·         Define who can print, manage documents, or manage the printer.

·         In Windows, use:

o    Control Panel > Devices and Printers > Printer > Properties > Security Tab

d. Monitoring and Managing Print Jobs

·         Use print queue to view, pause, or cancel jobs.

·         Use print management tools for logs, status, and priority settings.

5. Advantages of Network Printing

·         Cost-effective (fewer printers needed)

·         Centralized management

·         Easy to monitor usage and errors

·         Supports wireless/mobile printing

6. Tools for Managing Network Printers

·         Windows Print Management Console

·         CUPS (Linux/Unix)

·         Printer-specific Web Interface (e.g., HP, Canon)

7. Troubleshooting Network Printing

·         Check network connectivity (ping printer IP).

·         Ensure printer is online and has paper/ink.

·         Verify correct drivers are installed.

·         Restart the print spooler service (in Windows: services.msc).


3.9 Sharing Files, Folders, Printers, Applications, etc.

Sharing is a key feature in computer networks that allows users to access and use resources like files, folders, printers, and applications from other computers on the same network.

1. Sharing Files and Folders

Purpose:

·         To allow users on other systems to read, modify, or manage files stored on your computer.

Methods:

Windows:

·         Right-click file/folder → PropertiesSharing tab → Click "Share..."

·         Choose specific people or allow Everyone access.

·         Set permission levels: Read, Write, or Full Control.

Linux:

·         Use Samba for file sharing with Windows systems.

·         Use chmod, chown, and NFS for sharing among Linux systems.

Permissions:

·         Read: Can open the file.

·         Write: Can modify or delete.

·         Full Control: Can do everything, including changing permissions.

2. Sharing a Printer

Purpose:

·         Share a single printer with multiple users on a network.

Steps (Windows):

·         Go to Control Panel > Devices and Printers.

·         Right-click the printer → Printer PropertiesSharing tab.

·         Check "Share this printer" and assign a name.

Steps (Linux):

·         Use CUPS (Common Unix Printing System).

·         Enable printer sharing via web interface (http://localhost:631).

3. Sharing Applications

Purpose:

·         To allow multiple users to access or use an application (especially in client-server environments).

 Examples:

·         Web-based apps: Accessible through browsers (e.g., Gmail, Google Docs).

·         Remote Desktop: Access a full desktop or specific application remotely.

·         Application Server: Hosts applications that clients can access (e.g., ERP software).

Tools:

·         Remote Desktop Protocol (RDP) – for Windows.

·         VNC, SSH with X11 forwarding – for Linux.

4. Sharing Over the Network

Method

Description

HomeGroup / Workgroup

Used in Windows for basic home file and printer sharing (older versions).

Mapped Network Drive

Assigns a network folder as a local drive letter.

NFS (Network File System)

Used in Linux/Unix systems for sharing folders.

FTP (File Transfer Protocol)

Used for sharing files over a client-server model.

Cloud Sharing

Sharing via Google Drive, Dropbox, OneDrive, etc.

5. Security Considerations

·         Always set permissions based on user roles.

·         Use password protection.

·         Regularly monitor shared resources.

·         Use firewalls and encryption if sharing over the internet.

 

3.10 Installation and Configurations of Device Drivers, Applications, and Fonts

Installing and configuring device drivers, applications, and fonts is essential for ensuring that hardware and software components function properly in an operating system.

1. Device Drivers

What is a Device Driver?

·         A device driver is a software component that allows the operating system to communicate with hardware (printers, keyboards, display, etc.).

Installation Methods:

·         Automatic (Plug & Play): Modern OS auto-detects and installs drivers.

·         Manual Installation:

o    From CD/DVD or manufacturer’s website.

o    Use Device Manager in Windows.

§  Right-click on device > Update driver > Browse location.

·         Linux: Uses kernel modules and package managers (e.g., apt, dnf, modprobe).

Configuration:

·         Set device-specific settings (e.g., printer preferences, display resolution).

·         In Windows, use:

o    Control Panel > Devices and Printers

o    Device Manager

Updating/Uninstalling:

·         Windows: Device Manager > Right-click > Update or Uninstall.

·         Linux: Use terminal commands to install/remove drivers.

2. Applications (Software)

Installation Methods:

·         Windows:

o    Double-click .exe or .msi installer.

o    Use Microsoft Store or third-party websites.

·         Linux:

o    Use software manager (GUI-based) or terminal:

§  Debian/Ubuntu: sudo apt install appname

§  Red Hat/Fedora: sudo dnf install appname

·         macOS:

o    Drag app to the Applications folder or use App Store.

Configuration:

·         Configure settings after installation (language, account, update options).

·         Use Settings/Preferences in the app.

Uninstallation:

·         Windows: Control Panel > Programs > Uninstall a program.

·         Linux: sudo apt remove appname

·         macOS: Drag to Trash.

3. Fonts

What are Fonts?

·         Fonts are styles of text used in documents and applications.

Installation (Windows):

·         Download .ttf or .otf file.

·         Right-click → Install, or drag to:

o    C:\Windows\Fonts

Installation (Linux):

·         Copy fonts to ~/.fonts or /usr/share/fonts directory.

·         Run: fc-cache -f -v to refresh font cache.

Installation (macOS):

·         Use Font Book to install and manage fonts.

·         Drag files into the Font Book app.

Configuration:

·         Fonts can be selected in apps like MS Word, Photoshop, etc.

·         System-wide settings can be managed via Control Panel or Settings.

 

3.11 Identifying and Managing Security Threats to Operating Systems

Operating systems (OS) are prime targets for security threats because they control access to hardware and software resources. Proper identification and management of these threats are crucial to protect data, ensure privacy, and maintain system integrity.

1. Common Security Threats to Operating Systems

Threat

Description

Malware

Malicious software including viruses, worms, Trojans, ransomware, spyware, adware, etc.

Viruses and Worms

Self-replicating programs that damage files, consume resources, or spread to other systems.

Trojan Horses

Malware disguised as legitimate software to trick users into installing it.

Ransomware

Malware that encrypts data and demands payment to restore access.

Spyware/Adware

Software that secretly collects user data or shows unwanted ads.

Phishing Attacks

Attempts to steal sensitive information by masquerading as trustworthy entities.

Unauthorized Access

Hackers gaining access to systems without permission (via weak passwords, exploits).

Privilege Escalation

Exploiting vulnerabilities to gain higher access rights than intended.

Denial of Service (DoS)

Attacks that overwhelm system resources, making OS or services unavailable.

Rootkits

Malicious software that hides presence and activities of malware or hackers.

Backdoors

Hidden methods to bypass normal authentication and gain access.

2. Identifying Security Threats

·         Antivirus and Anti-malware Scans: Regular scanning for known malicious software.

·         Intrusion Detection Systems (IDS): Monitor system/network activity for suspicious behavior.

·         Audit Logs: Review logs for unauthorized access or abnormal operations.

·         Security Patches: Monitoring for OS vulnerabilities and patch releases.

·         Network Monitoring: Detect unusual traffic patterns indicating attacks.

·         User Reports: Alerts from users noticing abnormal system behavior.

 

 

3. Managing and Preventing Security Threats

Method

Description

Regular Updates and Patches

Keep OS and software updated to fix known vulnerabilities.

Strong Authentication

Use strong passwords, multi-factor authentication (MFA).

Access Controls & Permissions

Restrict user permissions to minimum necessary.

Firewalls

Block unauthorized inbound/outbound traffic.

Antivirus/Anti-malware Software

Detect and remove malicious software.

Backup and Recovery Plans

Regular backups to restore data after attacks like ransomware.

User Education

Train users to recognize phishing, suspicious downloads.

Encryption

Encrypt sensitive data to protect from unauthorized access.

System Hardening

Disable unnecessary services and ports, remove default accounts.

Monitoring and Logging

Continuous monitoring of logs and system activity.

Incident Response Plan

Have procedures ready to respond to and recover from security incidents.

4. Role of Operating System in Security

·         Enforces user authentication and authorization.

·         Manages file and resource permissions.

·         Implements security policies.

·         Supports encryption and secure communication protocols.

·         Provides audit trails and logs for security analysis.

 

3.12 Process Management, Memory Management, and I/O Management

These are three fundamental functions of an Operating System (OS) that ensure efficient use of hardware resources and smooth execution of applications.

1. Process Management

·         Definition: The OS manages processes—programs in execution—by creating, scheduling, and terminating them.

·         Key Functions:

o    Process Creation and Termination: OS creates processes when a program runs and deletes them when they finish.

o    Process Scheduling: Determines which process gets CPU time and for how long.

o    Context Switching: Saving and loading process states so multiple processes share CPU efficiently.

o    Process Synchronization: Coordinates processes to avoid conflicts, especially in accessing shared resources.

o    Inter-Process Communication (IPC): Enables processes to exchange data (e.g., pipes, shared memory).

·         Goal: Maximize CPU utilization and ensure fair process execution.

2. Memory Management

·         Definition: Manages the computer’s primary memory (RAM), allocating space to processes and ensuring efficient memory use.

·         Functions:

o    Memory Allocation & Deallocation: Assigns memory to processes when needed and frees it when done.

o    Memory Protection: Prevents one process from accessing memory allocated to another.

o    Virtual Memory: Uses disk space to simulate additional RAM, allowing larger programs to run.

o    Paging and Segmentation: Breaks memory into blocks (pages or segments) for easier management.

o    Swapping: Moves processes between main memory and disk to free RAM.

·         Goal: Optimize memory use, protect data, and support multitasking.

3. I/O Management

·         Definition: Manages input/output devices such as keyboards, printers, disks, and monitors.

·         Functions:

o    Device Drivers: Specialized programs that control specific hardware devices.

o    Buffering: Temporarily stores data while moving between processes and devices to handle speed differences.

o    Spooling: Queues data (e.g., print jobs) to be processed sequentially.

o    I/O Scheduling: Determines order in which I/O requests are processed to optimize performance.

o    Error Handling: Detects and manages errors during I/O operations.

·        
Goal: Efficient, reliable communication between the system and peripheral devices.

 

 

 

 

 



Post a Comment

0Comments

Post a Comment (0)