Wednesday, January 12, 2011

Operating System : Types of System Calls

Types of System Calls are:-

1. Process Control
  • end, abort
  • load, execute
  • create process, terminate process
  • allocate and free memory
  • get process attributes, set process attributes
2. File management
  • Create file, delete file
  • Open, close
  • Read, write, reposition
  • Get file attributes, set file attributes
3. Device management
  • Request device, release device
  • Logically attach and detach devices
  • Read, write, reposition
  • Get device attributes, set device attributes
4. Communication
  • Create, delete communication connections
  • Send, receive messages
  • Transfer status information
  • Attach or detach remote devices

Operating System: System Calls and System Programs

System Calls and System Programs

System calls provide an interface between the process and the operating system. System calls allow userlevel processes to request some services from the operating system which process itself is not allowed to do. For example, for I/O a process involves a system call telling the operating system to read or write particular area and this request is satisfied by the operating system.

System programs provide basic functioning to users so that they do not need to write their own environment for program development (e.g. editors, compilers) and program execution (shells). In some sense, they are bundles of useful system calls.

Types of System Calls are: Click Here

Operating System: Open Source & Distributed Systems

Open Source Operating System:-
The distribution of original source materials that can be studied, altered and built upon with the result once again freely distributed are called Open source.

Distributed Systems Operating System:-
A distributed system is a collection of physically separate, possibly heterogeneous computers systems that are networked to provide the users with access to the various resources that the system maintains. A Network is a communication path between two or more systems. Distributed system depends on networking for their functionality.

Application Interface & User Interface of Operating Systems os

Application Interface & User Interface of Operating

Application Interface and User Interface of Operating
Application Interface & User Interface of Operating
Application Interface of Operating Systems os

APIs lets application programmers use functions of the computer and OS without having to directly keep track of all the details in the CPU’s operation.

User Interface of Operating Systems os
A user interface (UI) brings structure to the interaction between a user and the computer.

Tasks of OS Operating System

Tasks of an OS Operating System

1. Process Management:-

The operating system manages many kinds of activities ranging from user programs to system programs. Each of these activities is encapsulated in a process. There are many processes can be running the same program. The five major activities of an operating system in regard to process management are
  • Creation and deletion of user and system processes.
  • Suspension and resumption of processes.
  • A mechanism for process synchronization.
  • A mechanism for process communication.
  • A mechanism for deadlock handling.
2. Memory Management:-
  • Keeping track of which parts of memory are currently being used and by whom.
  • Deciding which processes (or parts thereof) and data to move into and out of memory.
  • Allocating and deallocating memory space as needed.
3. Device Management:-
  • The assembling-disassembling of I/O peripherals devices are managed by the OS.

4. Storage Management:-
The three major activities of an operating system in regard to secondary storage management are:
  • Managing the free space available on the secondary-storage device.
  • Allocation of storage space when new files have to be written.
  • Scheduling the requests for memory access.

Transition from User Mode to Kernel Mode

Operating System (OS) Operations

Operating System OS has two modes of Operation:-

1. User mode
2. Kernel mode (Supervisor mode, system mode or privileged mode)

A bit called mode bit is added to the hardware of the computer to indicate the current mode: kernel (0) or user (1). With the mode bit, we are able to distinguish between a task that is executed on behalf of the OS and one that is executed on behalf of the user.

Transition from User to Kernel Mode
Transition from User to Kernel ModeWhen the computer system is executing on behalf of a user application, the system is in user mode. However, when a user application requests a service from the OS (via system call), it must transition from user to kernel mode to fulfill the request

At boot time, the hardware starts in kernel mode. The OS is then loaded and starts user
application in user mode.

What is Timer / What do you mean by Timer interrupt

Timer / Timer Interrupt

To prevent a user program from getting stuck in an infinite loop or not calling system services and never returning control to the OS, a timer is used. A timer can be set to interrupt the computer after a specified period.

Transition from User to Kernel Mode
Transition from User to Kernel ModeThe OS sets the counter and this counter is decremented every time the clock ticks. When the counter reaches 0, an interrupt occurs which transfers control automatically to the OS.