---
title: "Name service and name resolution"
subject: "Distributed System"
chapter: 2
key: "semester_7/distributed_system:name-service-types"
source: https://www.bctengineer.com/q/semester_7/distributed_system/name-service-types
site: BCT Engineering
---

# Name service and name resolution

Distributed System · Chapter 2: Distributed Objects and File System

- Asked in: Model question
- Video: [CS 407 Distributed Computing - Module 4 - Name Service](https://www.youtube.com/watch?v=Ch9qucDgQjQ) — Dept. of Computer Science & Engineering, CCE
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_7/distributed_system/name-service-types
- Whole chapter: https://www.bctengineer.com/md/semester_7/distributed_system/chapter-2

## Question

Define name service and explain its types. Explain the collection of name servers as a distributed system for the resolution of resource names along with resolution methods.

## Short answer

A name service maps names to attributes, with types: simple, directory, and discovery. Name servers distribute the namespace via partitioning and replication. Resolution methods include iterative (client queries each server), recursive (servers chain queries), and multicast, often with caching.

## Answer

#### Name service
A **name service** stores a collection of bindings between names and attributes (usually addresses) of resources, and answers lookup requests. It supports **name resolution**, finding the attributes of a resource from its name. Names are needed to identify resources independent of their location and to let them be shared. Examples: DNS, X.500/LDAP directory, CORBA naming service, the Jini lookup service.

#### Types of name service
1. **Name service (simple naming):** maps a name to attributes (usually addresses); example DNS.
2. **Directory service:** maps a name to a set of attributes and can search by attribute (find all printers in room 5); examples X.500, LDAP.
3. **Discovery service:** finds services in a spontaneous network (Jini lookup).

Names can also be *flat* (unstructured identifiers) or *structured* (hierarchical, as in DNS and file paths).

#### Name servers as a distributed system
A single name server would be a bottleneck and a single point of failure, so the name space is **partitioned** among many name servers, with replication, caching and delegation (as in DNS zones). Each server holds part of the data and knows how to reach the others. A lookup may navigate over several servers.

```text
 Client -> Local server -> Server X -> Server Y -> answer
```

#### Resolution (navigation) methods
- **Iterative navigation:** the client (its resolver) contacts one name server. If that server cannot resolve the whole name, it returns the address of another server that can resolve more of it, and the client contacts that server in turn, until the name is resolved (DNS works this way by default).
- **Multicast navigation:** the client multicasts the name to a group of name servers; only the server holding the binding replies (used for local discovery).
- **Non-recursive server-controlled navigation:** the client sends the name to one server, which itself contacts the other servers one by one (or by multicast) and returns the final answer to the client.
- **Recursive server-controlled navigation:** the contacted server passes the name to the server that holds the next part of the name space, which passes it on in turn; the result travels back along the chain to the client. It puts more load on servers, but lets them cache results, and works when clients cannot reach some servers directly.

**Caching** of results with timeouts, and **replication** of servers, improve performance and availability.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. What is name resolution?
   A. Assigning IP addresses to hosts
   B. Encrypting a name
   C. Finding the attributes (e.g. address) of a resource from its name
   D. Deleting unused bindings
   Answer: C. A name service stores bindings between names and attributes and resolves lookups. (Key point: Name resolution)

2. How does a directory service differ from a simple name service?
   A. It only stores addresses of hosts
   B. It can search by attributes, e.g. find all printers in a room
   C. It cannot map names at all
   D. It is used only for multicast
   Answer: B. Directory services (X.500, LDAP) map a name to attributes and allow attribute search. (Key point: Directory service)

3. Why is the name space partitioned among many name servers?
   A. A single server would be a bottleneck and a single point of failure
   B. To prevent caching
   C. To make names flat
   D. To avoid delegation
   Answer: A. Partitioning with replication, caching and delegation (DNS zones) improves scalability and availability. (Key point: Distribution)

4. In recursive navigation, who contacts the other name servers?
   A. Every server in the network by broadcast only
   B. Nobody; the lookup fails
   C. The client contacts each server in turn
   D. The contacted server does so on behalf of the client and returns the final answer
   Answer: D. In iterative navigation the client follows referrals; in recursive the server does the work, allowing server caching. (Key point: Navigation)

## Related in Distributed System

- [Autonomous vs distributed system](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Aautonomous-vs-distributed) — Distributed System, chapter 1
- [Models of distributed system](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Amodels-of-ds) — Distributed System, chapter 1
- [True distributed system; middleware organisation](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Atrue-ds-middleware) — Distributed System, chapter 3
- [Distributed deadlock and recovery](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Adistributed-deadlock-note) — Distributed System, chapter 8, asked 3×
- [DFS requirements and file service architecture](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Adfs-requirements-architecture) — Distributed System, chapter 2
- [Consensus; highly available service](https://www.bctengineer.com/question.md?key=semester_7%2Fdistributed_system%3Aconsensus-high-availability) — Distributed System, chapter 6

## Related in other subjects

- [Distributed parameters and current along a long line](https://www.bctengineer.com/question.md?key=semester_4%2Fpower_system_analysis_i%3Adistributed-parameters-long-line-current) — Power System Analysis I, chapter 5
- [Distributed system in big data example](https://www.bctengineer.com/question.md?key=semester_8%2Fbig_data_technologies%3Adistributed-system-example) — Big Data Technologies, chapter 1
- [Short note: Distributed system implementation](https://www.bctengineer.com/question.md?key=semester_6%2Fobject_oriented_analysis_and_design%3Ashort-note-distributed-implementation-issues) — Object Oriented Analysis and Design, chapter 4
- [Distributed system and Hadoop](https://www.bctengineer.com/question.md?key=semester_8%2Finformation_system%3Adistributed-system-hadoop-voluminous-data) — Information System, chapter 8
