os202

HOME


Top 10 List of Week 07

  1. Process Synchronization
    Process Synchronization is the task of coordinating the execution of processes in a way that no two processes can have access to the same shared data and resources. It is specially needed in a multi-process system when multiple processes are running together, and more than one processes try to gain access to the same shared resource or data at the same time.

  2. Deadlock
    Deadlock is a situation where a set of processes are blocked because each process is holding a resource and waiting for another resource acquired by some other process.

  3. Deadlock Characterization
    A deadlock happens in operating system when two or more processes need some resource to complete their execution that is held by the other process. There are 4 types of deadlocks: Mutual Exclusion, Hold and Wait, No Preemption, and Circular Wait.

  4. Race Condition
    A situation where several processes access and manipulate the same data concurrently, but because of the nature of the device or system, the operations must be done in the proper sequence to be done correctly.

  5. Livelock
    Livelock is a condition that takes place when two or more programs change their state continuously, with neither program making progress. Processes enter a state of livelock when they clash with each other’s state and fail to progress because both of them are changing the state, hence having the same state at a given time.

  6. Semaphore
    Semaphore was proposed by Dijkstra in 1965 which is a very significant technique to manage concurrent processes by using a simple integer value, which is known as a semaphore. Semaphore is simply a variable which is non-negative and shared between threads. This variable is used to solve the critical section problem and to achieve process synchronization in the multiprocessing environment. Semaphores are of two types: Binary Semaphore, Counting Semaphore.

  7. Critical Section
    When more than one processes access a same code segment that segment is known as critical section

  8. Mutex Locks
    As the synchronization hardware solution is not easy to implement for everyone, a strict software approach called Mutex Locks was introduced. In this approach, in the entry section of code, a LOCK is acquired over the critical resources modified and used inside critical section, and in the exit section that LOCK is released. As the resource is locked while a process executes its critical section hence no other process can access it.

  9. Massage Passing
    The most popular form of interprocess communication involves message passing. Processes communicate with each other by exchanging messages. A process may send information to a port, from which another process may receive information. The sending and receiving processes can be on the same or different computers connected via a communication medium.

One reason for the popularity of message passing is its ability to support client-server interaction. A server is a process that offers a set of services to client processes. These services are invoked in response to messages from the clients and results are returned in messages to the client. Thus a process may act as a web search server by accepting messages that ask it to search the web for a string.

  1. Deadlock Prevention
    Deadlock avoidance can be done with Bankers Algorithm. Bankerss Algorithm is resource allocation and deadlock avoidance algorithm which test all the request made by processes for resources, it checks for the safe state, if after granting request system remains in the safe state it allows the request and if there is no safe state it doesnt allow the request made by the process.