Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

There are two sites s1 and s2 and three transactions T1, T2, T3. The time table

ID: 664748 • Letter: T

Question

  There are two sites s1 and s2 and three transactions T1, T2, T3.

The time table is as follows

                           S1                                           S2

t1:             (T1, W, a)                                      (T3,W, b)

      t2:             (T2, R, b)                                       (T1, R, b)

      t3:             (T1, R, a)                                      

      t4:                                                                    (T2, R, c)

      t5:                                                                    (T3, R, c)

     Is there any deadlock in this distributed processing? Why?

Explanation / Answer

Given problem :

S1

S2

T1

T1,write,a

T3,write,b

T2

T2,read,b

T1,read,b

T3

T1,read,a

T4

T2,read,c

T5

T3,read c

Distrubuted deadlock :

t1: T1 initiated at site S1 and creating agent at S2

t2 : T2 initiated at site S1 and creating agent at s2 for T1

t3 initiated with reada with T1

t4 : reading T2

t5 : reading T3

Here only T1 seems to have deadlock. However there is no deadlock occurring overall

               Because nothing is forming a loop and the resource is not in waiting process. Hold and wait doesn’t result in distributed deadlock .

S1

S2

T1

T1,write,a

T3,write,b

T2

T2,read,b

T1,read,b

T3

T1,read,a

T4

T2,read,c

T5

T3,read c

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote