This set of Computer Networks Multiple Choice Questions & Answers (MCQs) focuses on “FTP”.
1. Expansion of FTP is __________
a) Fine Transfer Protocol
b) File Transfer Protocol
c) First Transfer Protocol
d) Fast Transfer Protocol
Explanation: File Transfer Protocol is an application layer protocol used to share “files” between a server and a client. The protocol uses two separate ports for data and control connections: port 20 for data and port 21 for control.
2. FTP is built on _____ architecture.
c) Data centric
d) Service oriented
Explanation: An FTP connection includes a Server and a Client which wish to share a number of data files. The server can transfer files with multiple clients at the same time while the client communicates with only one server at a time.
3. FTP uses _________ parallel TCP connections to transfer a file.
Explanation: Control connection using FTP port: 21, and data connection using FTP port: 20. The FTP session is started or ended using port 21 and the actual data i.e. files are sent through port 20.
4. Identify the incorrect statement regarding FTP.
a) FTP stands for File Transfer Protocol
b) FTP uses two parallel TCP connections
c) FTP sends its control information in-band
d) FTP sends exactly one file over the data connection
Explanation: FTP is out-of-band because the data connection is done separately through port 20 and control connection is done separately through port 21.
5. If 5 files are transferred from server A to client B in the same session. The number of TCP connections between A and B is _______
Explanation: The client would first initiate the TCP control connection through port 21. Then for every file transfer, a separate connection would be made through port 20. Now, since we have five files to be transferred, 1 control connection + 5 data connections = 6 total TCP connections.
6. FTP server _____________
a) Maintains state information
b) Is stateless
c) Has single TCP connection for a file transfer
d) Has UDP connection for file transfer
Explanation: FTP server maintains state information of every control connection to keep track of the active and inactive connections in the session. This helps the server decide which connection to terminate, in case the connection is inactive for too long.
7. The commands, from client to server, and replies, from server to client, are sent across the control connection in ________ bit ASCII format.
Explanation: FTP was designed to transmit commands only in English characters that are possible with just 7 bits in ASCII. Even the media has to be converted to ASCII before transmission.
8. Find the FTP reply whose message is wrongly matched.
a) 331 – Username OK, password required
b) 425 – Can’t open data connection
c) 452 – Error writing file
d) 452 – Can’t open data connection
Explanation: The correct response code for the message “Can’t open data connection” is 425. Response code 452 is sent usually when the connection is suddenly closed.
9. The data transfer mode of FTP, in which all the fragmenting has to be done by TCP is ________
a) Stream mode
b) Block mode
c) Compressed mode
d) Message mode
Explanation: Stream mode is the default mode of FTP, in which the TCP transforms/fragments the data into segments, and then after the transmission is completed, converts it back to stream of bytes.
10. The password is sent to the server using ________ command.
Explanation: The PASS command, preceded by the username, completes the user’s identification for access control in an FTP session. Without the valid password, the user won’t be able to initiate the FTP connection.
Sanfoundry Global Education & Learning Series – Computer Networks.
To practice all areas of Computer Networks, here is complete set of 1000+ Multiple Choice Questions and Answers.