MC0085 - Advanced Operating Systems
MC0085 - Advanced Operating Systems
b) Effi!ien!y ) Shoul re u!e the number of message ex!hanges ) A$oi the !osts of establishing an terminating !onne!tions between the same Pair of pro!esses for ea!h an e$ery message ) ) Piggyba!" a!"nowle gements with the normal messages Sen a!"nowle gements sele!ti$ely
!) %eliability ) Shoul han le no e an lin" failures ) *ormally han le by a!"nowle gements+ timeouts an retransmissions ) Shoul han le upli!ate messages that arise ue to retransmissions ,generally Se&uen!e numbers of the messages are use for this purpose) ) -orre!tness ) Atomi!ity: Messages sent to a group of pro!esses will be eli$ere to all of them .r none of them. ) .r ere ) eli$ery: Messages are re!ei$e by all re!ei$ers in an or er a!!eptable to the appli!ation Sur$i$ability: /uarantees messages will be eli$ere !orre!tly in spite of failures e) Flexibility ) #P- proto!ols shoul be flexible to !ater to the $arious nee s ifferent appli!ations ,i.e. some may not re&uire atomi!ity+ others maynot re&uire or ere eli$ery+ et!) ) #P- primiti$es shoul be flexible to permit any "in of !ontrol flow between !ooperating pro!ess+ in!lu ing syn!hronous an asyn!hronous sen an re!ei$e. f) Se!urity ) Message passing system shoul be !apable of pro$i ing se!ure en )to)en !ommuni!ation ) ) ) Support me!hanisms for authenti!ation of the re!ei$ers of a message by a sen er Support me!hanisms for authenti!ation of the sen er by its re!ei$ers Support en!ryption of a message before sen ing it o$er the networ"
g) Portability 'here are two ifferent aspe!ts of portability in a message passing system a. 'he message passing system shoul itself be portable. #t shoul be possible to
easily !onstru!t a new #P- fa!ility on another system by reusing the basi! esign of the existing message)passing system. b. 'he appli!ations written by using the primiti$es of the #P- proto!ols of the the message passing system shoul be ma e portable. 'his re&uires heterogeneity while esigning a message passing system. 'his may re&uire the use of external ata representation format for the !ommuni!ation ta"ing pla!e between two or more pro!esses running on !omputers of ifferent ar!hite!tures.
') 'ufferin" #n !omputing+ a buffer is a region of memory use to temporarily hol ata while
it is being mo$e from one pla!e to another. 'ypi!ally+ the ata is store in a buffer as it is retrie$e from an input e$i!e ,su!h as a "eyboar ) or 0ust before it is sent to an output e$i!e ,su!h as a printer). Buffers !an be implemente in either har ware or software+ but the $ast ma0ority of buffers are implemente in software. Buffers are typi!ally use when there is a ifferen!e between the rate at whi!h ata is re!ei$e an the rate at whi!h it !an be pro!esse + or in the !ase that these rates are $ariable+ for example in a printer spooler. 'he syn!hronous an asyn!hronous mo es of !ommuni!ation !orrespon to the two extremes of buffering: a null buffer+ or no buffering+ an a buffer with unboun e !apa!ity. 'wo other !ommonly use buffering strategies are single message an finite) boun + or multiple message buffers. 'hese four types of buffering strategies are gi$en below ( *o buffering ( #n this !ase+ message remains in the sen er1s a exe!utes the !orrespon ing re!ei$e. Single message buffer ( A buffer to hol a single message at the re!ei$er si e is use . #t is use for implementing syn!hronous !ommuni!ation be!ause in this !ase an appli!ation !an ha$e only one outstan ing message at any gi$en time 2nboun e ( -apa!ity buffer ( ress spa!e until the re!ei$er
-on$enient to support asyn!hronous !ommuni!ation. 3owe$er+ it is impossible to support unboun e buffer. Finite)Boun Buffer ( 2se for supporting asyn!hronous !ommuni!ation. Buffer o$erflow !an be han le in one of the following ways ( a) 2nsu!!essful !ommuni!ation: Sen returns an error message to the sen ing pro!ess+ in i!ation that the message !oul not be eli$ere to the re!ei$er be!ause the buffer is full. b) Flow) !ontrolle !ommuni!ation: 'he sen er is blo!"e until the re!ei$er a!!epts some messages. 'his $iolates the semanti!s or asyn!hronous sen . 'his will also result in !ommuni!ation ea lo!". A message ata shoul be meaningful to the re!ei$ing pro!ess. 'hat is+ that the stru!ture of the program shoul be preser$e while they are being transmitte from the a ress spa!e of the sen ing pro!ess to the a ress spa!e of the re!ei$ing pro!ess. #t is not possible in heterogeneous systems in whi!h the sen ing an re!ei$ing pro!esses are on !omputers of ifferent ar!hite!tures. E$en in homogeneous systems+ it is $ery iffi!ult to a!hie$e this goal as) a) An absolute pointer $alsue has no meaning ,more on this when we tal" about %P-). b) 4ifferent program ob0e!ts+ su!h as integers+ long integers+ short integers+ an !hara!ter strings+ o!!upy ifferent storage spa!e. So from the en!o ing of these ob0e!ts+ the re!ei$er shoul be able to i entify the type an si5e of the ob0e!ts. 'hese representations !an be use for en!o ing an a) 'agge representation 'he type of ea!h program ob0e!t as well as its $alue is en!o e in the message. 3ere+ it is a simple matter for the re!ei$ing pro!ess to !he!" the type of ea!h program ob0e!t in the message be!ause of the self) es!ribing nature of the !o e b) 2ntagge representation 'he message !ontains only program obn0e!ts+ no information is in!lu e in the message about the type pf ea!h program ob0e!t. 3ere+ the re!ei$ing ob0e!t shoul ha$e a prior "nowle ge of how to e!o e the re!ei$e not self) es!ribing. ata be!ause the !o e ata format is ata forms. e!o ing of a message ata (
'he untagge representations are use in S2*1s 64% format an tagge representation is use in Ma!h istribute operating system