Professional Documents
Culture Documents
Part I
CS403/534
Distributed Systems
Erkay Savas
Sabanci University
1
Overview
• Names, identifiers, and addresses
• Name resolution
• Name space implementation
• Locating mobile entities
• Removing unreferenced entities
2
Naming
• Names (character or bit strings) are used to
denote entities in a distributed system.
• Entity: resources, processes, users, mailboxes,
newsgroups, queues, web pages, etc.
• To operate on an entity, we need an access point.
• An access points is a special kind of entity whose
name is called address
– The address of an access point of an entity is also
called an address of that entity
– An entity may offer more than one access point
– Access point of an entity may change
• Address is a special kind of name
– It refers to an access point of an entity
3
Addresses as Names
• An entity may change its access point (so its
address)
• An access point may be reassigned for another
entity
• If an entity has multiple addresses, it is not
always obvious which one to choose from
performance point of view
• We need to uniquely identify an entity
• A location-independent name for an entity E, is
independent from the addresses of the access
points offered by E.
4
Identifiers
• A true identifier is a name with the following
properties:
• P1: An identifier refers to at most one entity
• P2: Each entity is referred to by at most one
identifier
• P3: An identifier always refers to the same
entity
n2 n3 n4 “/keys”
.twmrc mbox
“/home/steen/mbox”
Different path
No cycle!
names for the same
entity 7
Name Spaces (3)
• We can easily store all kinds of attributes in a node,
describing aspects of the entity the node represents:
– Address of the entity’s location,
– An identifier for that entity
– Type of the entity
– Nicknames, etc.
Example: UNIX file system
– Directory node represents a directory, leaf node a file
super
block file data blocks
10
Closure Mechanism
• So far in our examples, we have been given the
starting node and access to its directory table.
• The root node cannot be looked up since it has no
incoming edge.
• Knowing how and where to start name resolution
is generally known as closure mechanism.
– Selecting the initial node where the name resolution is
to start
– In UNIX, the inode of the root directory is the first
inode
11
Aliases
• Alias is another name for the same entity (e.g.
environment variable)
– Multiple absolute paths or symbolic links
• Hard link: What we have described so far as a
pathname. A name that is resolved by following a
specific path in the naming graph from one node
to another
• Soft (Symbolic) link: A leaf node O contains the
absolute pathname of another node (instead of
storing the address or state of the entity)
– First resolve O’s name (leading to O)
– Read the content of O, yielding, say, name
– Name resolution continues with name
12
Soft Link: Example
n2: “elke” n0
n3: “max” keys
home
n4: “steen” “/keys”
n5
n1
steen
elke max
n2 n3 n4
date stored in n6
keys “/keys”
.twmrc
mbox
n6 “/home/steen/keys”
nfs://flits.cs.vu.nl//home/steen
15
Global Name Service (1)
m0 home
n0 vu vu home
n0 m0
home mbox
keys
n1
steen n5
elke max “m0:/mbox”
n2 n3 n4
keys
.twmrc
mbox
n6 “n0:/home/steen/keys”
18
Name Space Distribution (1)
name server
5. #<ftp> cs node
#<nl,vu,cs,ftp>
<nl,vu,cs,ftp>
long-distance communication
nl
vu
cs
tornado
Zone: cs.vu.nl
30
DNS Implementation
An excerpt
from the
DNS
database for
the zone
cs.vu.nl.
The file
shows the
contents of
eight nodes
that are part
of
cs.vu.nl.
31
Glue to Another Zone
. (root)
nl
vu
cs
tornado
zone: cs.vu.nl
solo
32
Glue Record
cs.vu.nl NS solo.cs.vu.nl
solo.cs.vu.nl A 130.37.21.1
33
Reading Assignment
34