Tutorial Questions Flashcards

1
Q
  1. Why it is sometimes so hard to hide the occurrence and recovery from failures in a distributed system?
A

Detecting and recovering from failures in a distributed system is hard because it is generally hard to identify the states of remote software/hardware components. For example, it is generally impossible to detect whether a server is actually down, or that it is simply slow in responding

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q
  1. Why it is not always a good idea to aim at implementing the highest degree of transparency possible?
A

Considerable loss of performance.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q
  1. What is an open distributed system and what benefits does openness provide?
A

An open distributed system offers services according to clearly defined rules and interfaces. The same system can deliver the service to different type of clients and applications

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q
  1. Describe precisely what is meant by a scalable system.
A

Can scale geographically, with size and administration

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
  1. Scalability can be achieved applying different techniques. What are these techniques?
A

Workload and data distribution. This requires distributed/parallel algorithms  Using decentralized architecture  Data replication, and caching.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
  1. If a client and a server are placed far apart, we may see network latency dominating overall performance. How can we tackle this problem?
A

Use multithreaded clients and servers. Use a buffer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
  1. What’s a 3 tiered application?
A

Highest level is the client. Second level is the application and the lowest level is the data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q
  1. In a structured overlay network, messages are routed according to the topology of the overlay. What is an important disadvantage of this approach?
A

The shortest path between source and destination may not be the physical shortest path. While the source and receivers may be logically very close to each other, they could be physically at the remotest part of the network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q
  1. How interceptors can be used as an approach to adaptive software in distributed systems?
A

Interceptors offer a way to intercept the usual flow of the software/system and therefore enhance the existing applications with new functions (like logging). Good for context-awareness.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
  1. Discuss whether it is beneficial to limit the number of threads in a server process.
A
  • Threads require their own private stack. - Independent threads can be chaotic (can get race conditions).
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
  1. Assume a client calls an asynchronous RPC to a server, and subsequently waits until the server returns a result using another asynchronous RPC. Is this approach the same as letting the client execute a normal RPC?
A

No. An asynchronous RPC returns an acknowledgement to the caller, meaning that after the first call by the client, an additional message is sent across the network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
  1. Explain why transient synchronous communication has inherent scalability problems, and how these could be solved?
A
  1. The problem is the limited geographical scalability, which could result in large communication latency. Sysnchronous communication requires blocking until it receives the reply, so it may take a long time if there is distance.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q
  1. Give an example showing that multicasting can be useful for discrete data streams.
A

Passing a large file to many users

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q
  1. Give an example of where an address of an entity E needs to be further resolved into another address to actually access E.
A
  1. IP addresses in the Internet are used to address hosts. However, to access a host, its IP address needs to be further resolved to, for example, an Ethernet address (or a MAC address).
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
  1. What’s a true identifier?
A
  1. Book IBSM, Mac Address, Student number
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q
  1. In a hierarchical location service with a depth of k, how many location records need to be updated at most when a mobile entity changes its location?
A
  1. 2k + 1
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q
  1. Explain why transient synchronous communication has inherent scalability problems, and how these could be solved?
A
  1. The problem is the limited geographical scalability. Because synchronous communication requires that the caller is blocked until its message is received, it may take a long time before a caller can continue when the receiver is far away
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q
  1. Give an example showing that multicasting can be useful for discrete data streams.
A
  1. Passing a large file to many users as is the case, for example, when updating mirror sites for Web services or software distributions.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q
  1. Give an example of where an address of an entity E needs to be further resolved into another address to actually access E.
A
  1. IP addresses in the Internet are used to address hosts. However, to access a host, its IP address needs to be further resolved to, for example, an Ethernet address (or a MAC address).
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q
  1. In your own words explain why and how weak consistency matters in developing distributed systems.
A

Weak consistency models come from the need to replicate for performance. Because efficient replication can be done only if we can avoid global synchronisation, we then need to consider loosening consistency constraints

21
Q
  1. Active replication as described in the lecture notes requires that all operations be carried out in the same order at each replica. Is this ordering always necessary?
A

Active replication means a set of operations are propagated to other nodes in the system for data updates. It is important that the orders of these operations are obliged at each node. It is necessary to apply the operations in the same order across the system to ensure data consistency.

22
Q
  1. A file is replicated on 6 servers. a. List all the combinations of read and write quorums permitted by Gifford’s scheme.
A

NW which is more constrained (must be > N/2). So greater than 3… (4, 5, 6 are okay.) NR + NW > N so to take one case, for NW = 4, we can have NR values of 3 and above.

23
Q
  1. What is the significance of NR = 1?
A

You only need locate one copy to read, but writers need to communicate with all copies. This is valuable in a case where writes are relatively rare.

24
Q
A

Strict consistency means, every process reads the most recent write.

25
Q
A

Everybody reads in the same order. So b)

26
Q

How do you determine which ones are causally related?

A

“Writes that are potentially causally related must be seen by all processes in the same order. Concurrent writes may be seen in a different order on different machines.”

27
Q
A

Problem is P2 did not acquire the critical section for y, therefore R(y) by P2 returns NIL which is a unexpected output and could cause system failure.

28
Q

Explain general issues in choosing between client-centric and data-centric consistency models.

A

The big-picture issue is that client-centric models look at what happens when the client moves, whereas data-centric models look at what happens when a different process looks at the data from a different site.

On the one hand, data-centric models can be categorised into strong to weak models depends on how strict the synchronization rules are.

On the other hand, client-centric models focus on how various actions by a particular mobile client dictate the synchronization process.

29
Q

Which mechanisms could a distributed system provide as security services to application developers that believe only in the end-to-end argument in system’s design, as discussed in Chapter. 6 (Synchronisation)?

A

End-to-end argument to security services means that developers will not trust anything that is not provided by their own applications.

In effect, the distributed system as a whole is considered to be untrusted.

30
Q

Suppose you were asked to develop a distributed application that would allow teachers to set up exams. Give three example statements that would be part of the security policy for such an application.

A

Students should not be able to access exams before a specific time.

Also, any teacher accessing an exam before the actual examination date should be authenticated.

Also, there may be a restricted group of people that should be given read access to any exam in preparation, whereas only the responsible teacher should be given full access.

31
Q

What is wrong in implementing a nonce (see Textbook p.402) as a timestamp?

A

Although a timestamp is used only once, it is far from being random.

Implementations of security protocols exist that use timestamps as nonces, and which have been successfully attacked by exploiting the non-randomness of the nonces.

32
Q
A

In principle, if RB is never used again, then returning it unencrypted should be enough. However, such randomness is seldom found. Therefore, by encrypting RB, it becomes much more difficult for someone to break in and forge message 3.

33
Q

What is the role of the timestamp in message and why does it need to be encrypted?

A

The timestamp is used to protect against replays. By encrypting it, it becomes impossible to replay message 6 with a later timestamp. This example illustrates a general application of timestamps in cryptographic protocols.

34
Q
  1. How can role changes be expressed in an Access Control Matrix (see Textbook p.415)?
A

Roles, or protection domains in general, can be viewed as objects with basically a single operation: enter. Whether or not this operation can be called depends on the role from which the request is issued. More sophisticated approaches are also possible, for example, by allowing changes back to previous roles.

35
Q

Name a few advantages and disadvantages of using centralized servers for key management.

A

An obvious advantage is simplicity. Using a centralized server allows efficient storage and maintenance facilities at a single site.

Potential disadvantages include the server becoming a bottleneck with respect to performance as well as availability. Also, if the server is compromised, new keys will need to be established.

36
Q

Does it make sense to restrict the lifetime of a session key? If so, give an example how that could be established.

A

Session keys should always have a restricted lifetime as they are easier to break than other types of cryptographic keys. The way to restrict their lifetime is to send along the expiration time when the key is generated and distributed.

37
Q

What are the differences between computer-centric and user-centric approach to computing?

A

Computer-centric requires users to learn technology and interface, learning curve.

User-centric: self-adapting to user needs, self-configuring, context aware

38
Q

What is context information in pervasive context aware systems?

A

Context information is a set of data, gathered from sensors, applications and users, which conforms to a context model and provides a snapshot that approximates the real-world context at a given point in time

39
Q

What is the role of the Fusion Layer in processing sensed context information?

A

The Fusion Layer aggregates the location information gathered by the abstraction layer for a particular entity to provide a single, coherent location of the entity. If there are conflicts in the location information they should be resolved at this layer.

40
Q

What kind of communication paradigms are typically used in context-aware systems? Explain why.

A

Most pervasive applications/systems use notifications as a communication paradigm

RMI

41
Q

What is the difference between internal and external adaptations of applications? Give examples

A

Internal adaptation is the ability to coordinate potential adaptation within an application itself. For example, a GPS device and a network based location mechanism would be members of the same type of context (i.e. location). Both of these mechanisms can provide similar types of information but have different specifications and different requirements. When the system gets into a state whereby one of the mechanisms is favoured, the application will switch to the preferred mechanism.

External adaptation is the ability to coordinate the adaptive behaviour when resources become unavailable. For example, 2 adaptive applications run on a mobile device: a web browser and a video player. When a contextual change triggers (such as low of power in the phone) the adaptation control has to decide which adaptation mechanism should be invoked. This could be based on predefined policies such as priorities.

42
Q

. Explain why Byzantine failures require more replicated resources to deal with than silent failures.

A

Because erroneous results have to be voted down, you need a majority (50%+1) to detect Byzantine failures. On the hand, a silent failure produces no result and hence is not in contention for being part of the solution: provided a timeout or other suitable technique can detect the failure, only one correct alternative source of solution is needed.

43
Q

For each of the following applications, between the fault tolerant protocols: at-leastonce semantics and at-most-once semantics, which do you think is best?

Discuss.

a. Reading and writing files from a file server
b. Compiling a program
c. Remote banking

A

For (a) and (b), at least once is best. There is no harm trying over and over. For (c), it is best to give it only one try. If that fails, the user will have to intervene to clean up the mess.

44
Q
A

This is FIFO multicasting because P3 and P4 receives messages from P1 in the order that P1 sent the messages. Same for message from P2.

45
Q
A

This is atomic multicasting with total-order delivery of message because P3 and P4 receives messages from P1 and P2 in the same order.

46
Q

In our explanation of three-phase commit, it appears that committing a transaction is based on majority voting. Is this true?

A

Absolutely not. The point to note is that a recovering process that could not take part in the final decision as taken by the other process, will recover to a state that is consistent with the final choice made by the others.

47
Q

Given a server is stateless, are checkpoints necessary for recovery? Explain your example

A

It depends on what the server does. For example, a database server that has been handed a complete transaction will maintain a log to be able to redo its operations when recovering. However, there is no need to take checkpoints for the sake of the state of the distributed system. Checkpointing is done only for local recovery

48
Q
A