Suppose two programs A and B running on separate machines are both accessing a file X on an NFSv3 server. They do the following operations in this order: • A: open file X • A: write “1” to byte 0 of file X • B: open file X • B: write “3” to byte 0 of file X • B: write “4” to byte 1 of file X • A: write “2” to byte 1 of file X • A: read bytes 0-1 of file X[*****] • B: close file X • A: close file X • B: open file X • B: read bytes 0-1 of file X[-++++] • B: close file X Assume no operations overlap in time. For example, when A and B close the file the first time, the close for B, and everything required as a result of the close, completes entirely before the close for A starts. Question 1 (1 points): (see above) Suppose the machines A and B are running both do as much caching as is allowed by NFSv3 protocol and its open-to-close consistency model. Assume that they never need to evict values from the cache, except when required by the consistency model. What values would A read from file X in the read operation marked with ***** above? A 12 B. 14 C. 34 D. 32 Comments: Question 2 (1 points): (see above) Suppose the machines A and B are running both do as much caching as is allowed by NFSv3 protocol and its open-to-close consistency model. Assume that they never need to evict values from the cache, except when required by the consistency model. What values would B read from file X in th eread operation marked with +++++ above? A. O 32 B. 14 C. 12 D. 34 Comments: Show transcribed image text Suppose two programs A and B running on separate machines are both accessing a file X on an NFSv3 server. They do the following operations in this order: • A: open file X • A: write “1” to byte 0 of file X • B: open file X • B: write “3” to byte 0 of file X • B: write “4” to byte 1 of file X • A: write “2” to byte 1 of file X • A: read bytes 0-1 of file X[*****] • B: close file X • A: close file X • B: open file X • B: read bytes 0-1 of file X[-++++] • B: close file X Assume no operations overlap in time. For example, when A and B close the file the first time, the close for B, and everything required as a result of the close, completes entirely before the close for A starts. Question 1 (1 points): (see above) Suppose the machines A and B are running both do as much caching as is allowed by NFSv3 protocol and its open-to-close consistency model. Assume that they never need to evict values from the cache, except when required by the consistency model. What values would A read from file X in the read operation marked with ***** above? A 12 B. 14 C. 34 D. 32 Comments: Question 2 (1 points): (see above) Suppose the machines A and B are running both do as much caching as is allowed by NFSv3 protocol and its open-to-close consistency model. Assume that they never need to evict values from the cache, except when required by the consistency model. What values would B read from file X in th eread operation marked with +++++ above? A. O 32 B. 14 C. 12 D. 34 Comments:
Expert Answer
Answer to Suppose two programs A and B running on separate machines are both accessing a file X on an NFSv3 server. They do the fo…