You are on page 1of 6

CCNA Exploration Chapter 4 OSI transport layer. Study answers. 4.

1
In the source host, data comes to the transport layer from which layer? OSI session layer 5 session layer or TCP/IP application layer. In the source host, data leaves the transport layer and goes to which layer? OSI network layer 3 network layer or TCP/IP internet layer. What is the purpose of the transport layer? The Transport layer is responsible for the overall end-to-end transfer of application data. It encapsulates application data for transport, passing it to the network layer and it processes incoming data from the network layer, passing it to the application (or session) layer. What must the transport layer do with the segments that arrive at the destination host? Identify which segments belong together and reassemble them into a data stream, then direct the data stream to the correct application layer protocol. What does the transport layer use to identify the application layer protocol that produced the data on the source host and needs to process the data on the destination host? It uses port numbers. Why is there more than one transport layer protocol in regular use? Different types of application data have different requirements. Some types of data can tolerate some data loss or data in the wrong order, and other types of data cannot. Some types of data can tolerate delay and some cannot. Give an example of a type of data that can tolerate some delay but must arrive complete and in the right order. E-mail, web page. Give an example of a type of data that cannot tolerate delay, but can tolerate some loss or data. Phone conversation, streaming video.

The transport layer carries out multiplexing. What does this mean? The transport layer splits the data into segments. Segments from different applications or conversations can be interleaved before being sent. If data from different conversations is multiplexed, how is the transport layer at the receiving host able to sort out the different conversations and reassemble the data? It uses port numbers. What is meant by reliable delivery? Any lost segments are re-sent so that the data is complete when it is reassembled. Why does the transport layer not use reliable delivery for all application data? Reliable delivery involves more overhead on the network because of the extra messages needed for acknowledgements and re-sending. This causes some delay. Speed is more important than reliability for some types of data. The TCP/IP protocol stack has two common transport layer protocols. Which provides reliable delivery? TCP. And which does not? UDP. Why is the TCP segment header bigger than the UDP datagram header? The UDP header contains only the essential addressing information (port numbers), the length and a checksum. The TCP header also includes fields that are needed for reliability and flow control. What is the advantage of using flow control? It controls the amount of data sent at one time, so that the destination host is not receiving data faster than the data can be processed. A client host is requesting a web page from a server. What destination port number goes in the segment header, and why? The destination port number is 80. This is the default number assigned to the HTTP application layer protocol.

A client host is requesting a web page from a server. How does it choose the source port number to go in the segment header? The number is chosen at random. What is a socket? The combination of an IP address and a port number. What is the range of numbers for well known ports, and what are these numbers used for? 0 to 1023. They are assigned to common services and applications such as HTTP, SNMP. What is the range of numbers for designated ports, and what are they used for? 1024 to 49151. They can be assigned to applications that do not have well known port numbers, or they can be chosen at random as source port numbers. What is the name given to port numbers 49152 to 65535? Private ports, dynamic ports or ephemeral ports. What TCP ports are used by: Telnet, HTTP, POP3, SMTP, FTP? 23 Telnet, 80 HTTP, 110 POP3, 25 SMTP, 21 FTP What UDP ports are used by: TFTP, RIP, Cisco SCCP? 69 TFTP, 520 RIP, 2000 Cisco SCCP? Which application layer protocol sometimes uses TCP and sometimes uses UDP, but uses port 53 for either. DNS. What command can you give on a host to show network connections and list the protocol in use, the local address and port number, the foreign address and port number, and the state of the connection? Netstat Why does the transport layer split data into segments? There will be a limit to the size of data unit that can be sent across the network. It also allows data segments to be multiplexed so that several applications can send data at the same time.

Segments may take different paths across networks and arrive in the wrong order. How do TCP and UDP handle this? TCP puts sequence numbers in the segment headers so that it can sort the segments into the right order before assembling them. UDP just assembles the segments in the order they arrive, even if this is wrong.

4.2
TCP is connection oriented. What does this mean? TCP sets up a connection between the source and destination hosts before starting to send data. What is the three way handshake? This is the process of setting up the connection between hosts. Client A starts the three way handshake by sending a SYN message with SEQ number 200 to server B. How will server B reply? Server B sends a SYN/ACK message with its own SEQ number and ACK number 201. Client A sends the third message of the three way handshake. What ACK number will it send? One greater than the SEQ number it received from server B. How does server B know that the message it is receiving is an ACK message? The ACK flag is set (value 1). When the hosts have finished exchanging application data, how many steps does it take to close the connection? Four. How does a host know that it is receiving a message to close the connection? The FIN flag is set. The initial sequence number is set before data transmission starts. How does the sequence number change as data is sent? It is incremented by the number of bytes that have been transmitted.

4.3
TCP uses expectational acknowledgement. What is this? The receiving host sends an acknowledgement. It contains an ACK number which is the number of the byte that it expects to receive next. This shows the sender that all previous bytes have been received. What is the window size in TCP? The amount of data that will be sent before the sender pauses and waits for an acknowledgement. The source host sends segments with sequence numbers 1000 to 1999. They all arrive safely. What will the destination host send in reply? ACK 2000. The source host sends segments with sequence numbers 2000 to 3999. The segments with numbers 2000 to 3599 all arrive safely but the others are lost. What will the destination host send in reply? ACK 3600 The source host sends segments with sequence numbers 2000 to 3999. None of them arrive. What happens? The source sets a timer running when it sends. It will wait for an acknowledgement. Since no acknowledgement comes, the timer will run out. The source will then send the data again. When is the initial window size for a transmission decided? It is set during the three way handshake. What might make the window size smaller? If the destination host cannot process the data fast enough and its buffer is overflowing do that data is lost, it will set a smaller window size. What might make the window size larger? If all the data is received correctly then the destination host will increase the window size. Why is it good to have the window size as large as it can be without losing data? There are fewer acknowledgements and therefore less overhead on the network.

4.4
Why is UDP used rather than TCP for applications such as DNS, SNMP, DHCP and TFTP? There is less overhead and therefore less delay. UDP is connectionless and best effort. What does this mean? It does not set up a connection before transmitting data, and it does not have any system of acknowledgement to check if data has arrived. It just sends the data. It takes no action if the data is lost. The transport layer PDU is called the segment when the protocol is TCP. The UDP data unit is sometimes called a segment, but can also be called: A datagram. (But this is a general term that is sometimes also used for a packet.) Does UDP always split application data into a series of datagrams? No. Some applications that use UDP send small amounts of data that fit into single datagrams or segments.

You might also like