Algorithm for implementing Distributed Shared Memory Last Updated : 14 Jun, 2022 Comments Improve Suggest changes 5 Likes Like Report Distributed shared memory(DSM) system is a resource management component of distributed operating system that implements shared memory model in distributed system which have no physically shared memory. The shared memory model provides a virtual address space which is shared by all nodes in a distributed system. The central issues in implementing DSM are: how to keep track of location of remote data. how to overcome communication overheads and delays involved in execution of communication protocols in system for accessing remote data. how to make shared data concurrently accessible at several nodes to improve performance. Algorithms to implement DSM 1. Central Server Algorithm: In this, a central server maintains all shared data. It services read requests from other nodes by returning the data items to them and write requests by updating the data and returning acknowledgement messages. Time-out can be used in case of failed acknowledgement while sequence number can be used to avoid duplicate write requests. It is simpler to implement but the central server can become bottleneck and to overcome this shared data can be distributed among several servers. This distribution can be by address or by using a mapping function to locate the appropriate server. 2. Migration Algorithm: In contrast to central server algo where every data access request is forwarded to location of data while in this data is shipped to location of data access request which allows subsequent access to be performed locally. It allows only one node to access a shared data at a time and the whole block containing data item migrates instead of individual item requested. It is susceptible to thrashing where pages frequently migrate between nodes while servicing only a few requests. This algo provides an opportunity to integrate DSM with virtual memory provided by operating system at individual nodes. 3. Read Replication Algorithm: This extends the migration algorithm by replicating data blocks and allowing multiple nodes to have read access or one node to have both read write access. It improves system performance by allowing multiple nodes to access data concurrently. The write operation in this is expensive as all copies of a shared block at various nodes will either have to invalidated or updated with the current value to maintain consistency of shared data block. DSM must keep track of location of all copies of data blocks in this. 4. Full Replication Algorithm: It is an extension of read replication algorithm which allows multiple nodes to have both read and write access to shared data blocks. Since many nodes can write shared data concurrently, the access to shared data must be controlled to maintain it's consistency. To maintain consistency, it can use a gap free sequences in which all nodes wishing to modify shared data will send the modification to sequencer which will then assign a sequence number and multicast the modification with sequence number to all nodes that have a copy of shared data item. Create Quiz Comment A Ankit87 Follow 5 Improve A Ankit87 Follow 5 Improve Article Tags : Operating Systems Distributed System Explore OS BasicsIntroduction to Operating System5 min readTypes of Operating Systems7 min readKernel in Operating System3 min readSystem Call2 min readWhat happens when we turn on computer?3 min readProcess ManagementIntroduction of Process Management4 min readCPU Scheduling in Operating Systems7 min readIntroduction to Process Synchronization4 min readSolutions to Process Synchronization Problems4 min readClassical IPC Problems2 min readIntroduction of Deadlock in Operating System3 min readHandling Deadlocks2 min readMultithreading in OS - Different Models4 min readMemory ManagementIntroduction to memory and memory units2 min readMemory Management in Operating System5 min readBuddy System - Memory Allocation Technique4 min readOverlays in Memory Management4 min readVirtual Memory in Operating System7 min readPage Replacement Algorithms in Operating Systems5 min readOperating system based Virtualization5 min readI/O ManagementFile Systems in Operating System4 min readImplementing Directory Management using Shell Script3 min readSecondary Memory7 min readDisk Scheduling Algorithms9 min readDifference between Spooling and Buffering5 min readImportant LinksLast Minute Notes â Operating Systems15+ min readOperating System Interview Questions15+ min read Like