Fault Tolerance Protocol Part-II

Fault Tolerance in DSS ARRAY MIRROR_LIST; INT FREE_SPACE; INT RESERVED_SPACE; INT OCCUPIED_SPACE; FN= FAILURE NOTIFICATION N =GENERAL NODE; NN= NEXT NODE TN=TRACING NEIGHBOUR; TgtN=TARGET NODE; FS= FILE SIZE; FH= FILE HASH; MR= MIRROR REQUEST; SDFN= SHUTTING DOWN FAILURE NOTIFICATION; SN=SHUT DOWN NODE; TS=TIMER START; TO=TIMES OUT; 1. If (N is ShuttingDown)


 * N broadcasts SDFN to all node in MIRROR_LIST


 * SN = N


 * SDFN(N,FS,FH)



At Receiving End  TS (Timer Starts) if(TO) then 1.1 if (NN != N)  At NN's end if (FREE_SPACE > FS) then FREE_SPACE = FREE_SPACE - FS; RESERVED_SPACE = RESERVED_SPACE + FS;
 * if (NN reply with FN2)
 * FN2 {"AMMIRROR"}
 * Then NN=TN;
 * repeat 1.1;
 * Else if (NN reply with FN3)
 * FN3 {PORT No.}
 * send file

At NN's end On File Transfer complete OCCUPIED_SPACE = OCCUPIED_SPACE + FS; RESRVED_SPACE = RESERVED_SPACE - FS;
 * Else If (NN reply with FN4)
 * FN4{NO_SPACE}
 * NN++
 * repeat step 1.1


 * Else IF(!TO)


 * repeat step 1