Chapter 2 Services and Components of Operating System By Ms. H. C Kunwar Lecturer

Published on Slideshow
Static slideshow
Download PDF version
Download PDF version
Embed video
Share video
Ask about this video

Scene 1 (0s)

Chapter 2 Services and Components of Operating System By Ms. H. C Kunwar Lecturer.

Scene 2 (10s)

Operating System Services. Operating systems provide an environment for execution of programs and services to programs and users 1. User interface : - Almost all operating systems have a user interface (UI) Varies between Command-Line (CLI) , Graphics User Interface (GUI) , Batch 2. Program execution : - The system must be able to load a program into memory and to run that program, end execution, either normally or abnormally (indicating error). 3. I/O operations : - A running program may require I/O, which may involve a file or an I/O device 4. File-system manipulation : - The file system is of particular interest. Programs need to read and write files and directories, create and delete them, search them, list file Information, permission management..

Scene 3 (43s)

Operating System Services (Cont.). 5. Communications :– Processes may exchange information, on the same computer or between computers over a network Communications may be via shared memory or through message passing (packets moved by the OS) 6. Error detection : – OS needs to be constantly aware of possible errors May occur in the CPU and memory hardware, in I/O devices, in user program For each type of error, OS should take the appropriate action to ensure correct and consistent computing Debugging facilities can greatly enhance the user’s and programmer’s abilities to efficiently use the system.

Scene 4 (1m 10s)

Operating System Services (Cont.). 6. Resource allocation :- When multiple users or multiple jobs running concurrently, resources must be allocated to each of them Many types of resources - Some (such as CPU cycles, main memory, and file storage) may have special allocation code, others (such as I/O devices) may have general request and release code 7. Accounting :- To keep track of which users use how much and what kinds of computer resources 8. Protection and security:- The owners of information stored in a multiuser or networked computer system may want to control use of that information, concurrent processes should not interfere with each other Protection involves ensuring that all access to system resources is controlled Security of the system from outsiders requires user authentication, extends to defending external I/O devices from invalid access attempts.

Scene 5 (1m 45s)

A View of Operating System Services. 2.

Scene 6 (1m 52s)

System Calls. System call is an interface between a running program and operating system. It allows user to access services provided by operating system. This system calls are procedures written using C,C ++ and assembly language instructions . The interface between a process and an operating system is provided by system calls. Each operating system has its own name for each system call. Each system call is associated with a number that identifies itself System calls are usually made when a process in user mode requires access to a resource. Then it requests the kernel to provide the resource via a system call..

Scene 7 (2m 19s)

System Call Implementation. Typically, a number associated with each system call System-call interface maintains a table indexed according to these numbers. The system call interface invokes intended system call in OS kernel and returns status of the system call and any return values. The caller need know nothing about how the system call is implemented Just needs to obey API and understand what OS will do as a result call. Most details of OS interface hidden from programmer by API..

Scene 8 (2m 41s)

How System C all Implemented. 2.

Scene 9 (2m 47s)

Types of System Calls. Process control end, abort load, execute create process, terminate process get process attributes, set process attributes wait for time wait event, signal event allocate and free memory File management create file, delete file open, close file read, write, reposition get and set file attributes.

Scene 10 (3m 4s)

Types of System Calls (Cont.). Device management request device, release device read, write, reposition get device attributes, set device attributes logically attach or detach devices Information maintenance get time or date, set time or date get system data, set system data get and set process, file, or device attributes Communications create, delete communication connection send, receive messages transfer status information attach and detach remote devices.

Scene 11 (3m 25s)

Examples of Windows and Unix System Calls. OS8 p61.

Scene 12 (3m 33s)

Operating System Components. Process Management Main Memory Management Secondary-Storage Management I/O System Management File Management.

Scene 13 (3m 42s)

Process Management. A process is a program in execution. A process needs certain resources, including CPU time, memory, files, and I/O devices, to accomplish its task. The operating system is responsible for the following activities in connection with process management. Process creation and deletion. process suspension and resumption. Provision of mechanisms for: process synchronization process communication.

Scene 14 (4m 1s)

Main-Memory Management. Memory is a large array of words or bytes, each with its own address. It is a repository of quickly accessible data shared by the CPU and I/O devices. Main memory is a volatile storage device. It loses its contents in the case of system failure. The operating system is responsible for the following activities in connections with memory management: Keep track of which parts of memory are currently being used and by whom. Decide which processes to load when memory space becomes available. Allocate and deallocate memory space as needed..

Scene 15 (4m 27s)

Secondary-Storage Management. Since main memory ( primary storage ) is volatile and too small to accommodate all data and programs permanently, the computer system must provide secondary storage to back up main memory. Most modern computer systems use disks as the principle on-line storage medium, for both programs and data. The operating system is responsible for the following activities in connection with disk management: Free space management Storage allocation Disk scheduling.

Scene 16 (4m 47s)

I/O System Management. The I/O system consists of: A buffer-caching system A general device-driver interface Drivers for specific hardware devices.

Scene 17 (4m 58s)

File Management. A file is a collection of related information defined by its creator. Commonly, files represent programs (both source and object forms) and data. The operating system is responsible for the following activities in connections with file management: File creation and deletion. Directory creation and deletion. Support of primitives for manipulating files and directories. Mapping files onto secondary storage. File backup on stable (nonvolatile) storage media..

Scene 18 (5m 18s)

Use of Operating System Tools. Following are the operating tools : User Management Security policy Device Management Performance Monitor Task Scheduler.

Scene 19 (5m 28s)

Use of Operating System Tools(cont..). 1. User Management:.

Scene 20 (5m 53s)

Use of Operating System Tools(cont..). 2 . Device Management :.

Scene 21 (6m 15s)

Use of Operating System Tools(cont..). 3. Performance Monitor: It is very tough job for every system or network administrator to monitor and debug Linux System Performance problems every day. The commands discussed below are some of the most fundamental commands when it comes to system analysis and debugging Linux server issues such as: vmstat : Virtual memory statistics The vmstat command reports information about processes, memory, paging , block IO, traps, and cpu activity. Eg . $ vmstat 3.

Scene 22 (6m 37s)

Use of Operating System Tools(cont..). 3. Security Policy: Security policies cover all preventative measures and techniques to ensure the safeguarding of an OS, the network it connects to, and the data which can be stolen, edited or deleted. OS security policies and procedures cover a broad area (i.e. from threats to attacks), there are many ways to address them. Some of these areas include: Ensuring systems are patched or updated regularly. Installing and updating anti-virus software. Installing a firewall and ensuring it is configured properly to monitor all incoming and outgoing traffic. Implementing user management procedures secure user accounts and privileges..

Scene 23 (7m 5s)

Use of Operating System Tools(cont..). 3. Task Scheduler: The Task Scheduler is a tool included with Windows that allows predefined actions to be automatically executed whenever a certain set of conditions is met . For example, you can schedule a task to run a backup script every night, or send you an e-mail whenever a certain system event occurs.

Scene 24 (7m 21s)

Thank You End of Chapter 2.