Algorithm for implementing Distributed Shared Memory

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 cam 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: