Download CS335 Sample Questions for Exam #2

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Net bias wikipedia , lookup

CAN bus wikipedia , lookup

Backpressure routing wikipedia , lookup

Multiprotocol Label Switching wikipedia , lookup

RapidIO wikipedia , lookup

AppleTalk wikipedia , lookup

Piggybacking (Internet access) wikipedia , lookup

Asynchronous Transfer Mode wikipedia , lookup

TCP congestion control wikipedia , lookup

Deep packet inspection wikipedia , lookup

Distributed firewall wikipedia , lookup

List of wireless community networks by region wikipedia , lookup

IEEE 802.1aq wikipedia , lookup

Network tap wikipedia , lookup

Wake-on-LAN wikipedia , lookup

Computer network wikipedia , lookup

Airborne Networking wikipedia , lookup

Internet protocol suite wikipedia , lookup

IEEE 1355 wikipedia , lookup

Zero-configuration networking wikipedia , lookup

Routing wikipedia , lookup

UniPro protocol stack wikipedia , lookup

Cracking of wireless networks wikipedia , lookup

Recursive InterNetwork Architecture (RINA) wikipedia , lookup

Routing in delay-tolerant networking wikipedia , lookup

Transcript
CS335 Sample Questions for Exam #2
1.) Compare connection-oriented with connectionless protocols. What type of
protocol is IP? How about TCP and UDP?
Answer:
Connection-oriented protocols
Require a setup time to establish a connection
Always receive data in the order that it was sent.
Tend to be more reliable
Connection-less protocols
Require no setup time
Can receive data out of order
Tend to be less reliable
•
•
•
IP is an unreliable connectionless protocol.
TCP is a reliable connection-oriented protocol.
UDP is an unreliable connectionless protocol.
2.) Which of the following are guaranteed under IP?
×
×
×
×
×
Packets will arrive in the same order that they are sent.
IP uses the IP address stored in each datagram to route the packet.
IP packets will contain both source and destination IP addresses.
IP uses the port number stored in each datagram to route the packet.
Packets contain uncorrupted data.
Packets have a fixed length.
After the connection is established, packets all take the same route.
3.) Are packets sent inside frames, or is it frames inside packets? What about TCP
segments?
Answer:
Data from higher layers are encapsulated inside transmission units of lower
layers. Thus a data link layer frame might contain a network layer packet which
might contain a TCP segment.
4.) What is the MTU and what does it have to do with datagrams?
Answer:
MTU is the Maximum Transmission Unit. It is the maximum size for data link
layer frames. When a datagram will not fit inside a single frame, it must be
fragmented (divided into smaller packets).
5.) If a datagram is fragmented on the first hop on route to its destination, will the
destination host necessarily know that the packet was fragmented?
Answer:
Yes, because the packet will remain fragmented until it arrives at the final
destination.
6.) Is there a maximum number of routers that a packet can pass through on its way
to its destination? Why or why not?
Answer:
Yes, because the time to live value is decremented at each hop. The time to live
is fixed size (8-bits) so there can be no more than 255 hops.
7.) How can we tell a class B network address from a class C network address?
Answer: The first few bits of the address specify the class.
Which address class provides more host addresses per network?
Answer: A class “B” network provides close to 64K host addresses per network,
while a class “C” network provides about 256 host addresses per network.
Which address class allocates more network addresses?
Answer: A class “C” network provides more network addresses.
8.) What is subnetting, and how is it different from supernetting?
Answer: Subnetting utilizes address bits that the class designated as host address
bits to extend the network address. Supernetting utilizes address bits that the class
designated as network address bits to extend the host address.
9.) Suppose that we want to split a network with address 123.132.23.0/24 into 16
subnets. How many hosts could we put on each subnet?
10.)
Answer: In a class “C” network there 8 bits allocated for the host address.
Subnetting to create 16 subnets will require log216 bits = 4 bits. The remaining bits
will provide 24 = 16 host addresses. Two of these addresses are reserved for
broadcasting and to specify “this host,” leaving 14 addresses available for hosts.
11.)
What is the special significance of the following addresses?
1.) 0.0.0.0
♦ The address of “this host.” (the primary IP address of the machine
executing the instruction.
2.) 0.0.0.18
♦ The host with the host address 18 on “this local network.”
3.) 255.255.255.255
♦ Broadcast
4.) 161.115.255.255
♦ Broadcast on network 161.115
5.) 127.0.0.1
♦ The address of “this host.” (loopback)
12.)
Suppose host 161.115.144.19/16 wants to send a message to host
161.115.144.120/16. What is the minimum number of routers the packets have to
pass through? How is this determined?
Answer:
♦ There are 16 bits of the IP address allocated for the network address,
while the remaining 16 bits are used to specify the host address. So
the network address for both machines is 161.115. Because both the
source and destination are on the same network, the message will not
have to pass through any routers.
will be stored in a table for later use.
13.)
CS335: What does the fork() system call do? When would we want to
use it?
Answer:
The fork() system call, which is supported under Unix but not Windows, creates a
child process that is identical to the parent process in every respect with the
exception of the return status from the fork call itself.
The fork call is often used in network servers that handle multiple clients. Each
time a client connects to the server, a new child process is created to handle the
client’s requests. The parent process is then available to await other client
connections.
14.)
Which of the following protocols are transport-layer protocols?
× IP
TCP
UDP
15.)
Under which of the following protocols can data arrive out of order?
× TCP
UDP
16.)
Which of the following protocols is reliable
TCP
× UDP
17.)
Which of the following protocols is connection-oriented
TCP
× UDP
18.)
Which two network layers utilize sliding window protocols?
Answer:
Data link layer and transport layer.
19.)
Are TCP segments ever contained in packets?
Answer: Yes, lower-layer transmission units can contain higher-layer transmission units.
Are packets ever contained in TCP segments?
Answer: No, lower-layer transmission units can contain higher-layer transmission units,
but not the other way around.
Are frames ever contained in TCP segments?
Answer: No, lower-layer transmission units can contain higher-layer transmission units,
but not the other way around.
20.)
For each of the following, identify whether it occurs as part of distance
vector routing, link state routing, flooding, or some combination.
1.) Perform Dijkstra’s all shortest paths algorithm.
i. Link state routing
2.) Shortest paths are always followed.
i. Link state routing
ii. Flooding
3.) Only neighbors exchange information about their routes.
i. Distance vector routing
4.) Non-neighbors exchange information about their routes.
i. Link state routing
5.) Routing tables entries are determined.
i. Distance vector routing
ii. Link state routing
6.) The algorithm determines the complete topology of the network.
i. Link state routing
7.) The count to infinity problem might be encountered.
i. Distance vector routing
8.) The procedure must be repeated multiple time to generate good results.
i. Distance vector routing
9.) Neighbors might lie about the best routes they know.
i. Distance vector routing
21.)
Consider the network shown in the figure.
1
C
3
1
3
A
B
2
D
E
1
6
G
2
1
F
2
Using distance vector routing:
a.) Show the data that node A will receive on the first iteration of the
algorithm.
Answer:
From ode C:
B, 3
E, 1
From ode D:
B, 2
F, 1
From ode E:
C,1
F, 1
G, 6
b.) Show the routing table for node A after the first iteration of the
algorithm has been completed. (6 pts)
Answer:
A, 0, A
B, 4, C
C, 1, C
D, 2, D
E, 2, C
F, 3, D
G, 8 (or 9), E
22.) Use Dijkstra’s all shortest paths algorithm to determine the shortest
paths to node A. Record the order in which the nodes are made
permanent along with the next hop and the distance to the destination.
1
C
1.8
1
4
A
B
1
D
E
1
1.5
G
2.5
1
F
0.3
Answer:
ode ame
A
C
E
D
B
F
G
Distance to Destination
0
1
2
2.5
2.8
3
3.3
ext hop
A
A
C
A
C
E
F