61. What is the difference between a router and a switch?
- A router operates at Layer 2; a switch operates at Layer 3
- A router connects different networks using IP addresses; a switch connects devices within the same network using MAC addresses
- A switch can connect to the internet; a router cannot
- There is no difference — they perform the same function
Answer : B Explanation: A router operates at Layer 3 (Network Layer) and connects different networks by routing packets based on IP addresses — for example, connecting your home network to the internet. A switch operates at Layer 2 (Data Link Layer) and connects multiple devices within the same network, forwarding data frames based on MAC addresses. Modern Layer 3 switches can also perform some routing functions.
62. What is OSPF and at which layer does it operate?
- Open Shortest Path First — operates at Layer 2
- Open Shortest Path First — a dynamic routing protocol that operates at Layer 3
- Open System Protocol Framework — operates at Layer 4
- Optimal Shortest Path Forwarding — operates at Layer 1
Answer : B Explanation: OSPF (Open Shortest Path First) is a link-state dynamic routing protocol that operates at Layer 3 (Network Layer). It uses Dijkstra’s shortest path algorithm to find the best route between networks. OSPF is widely used in large enterprise networks because it converges faster than RIP, supports VLSM (Variable Length Subnet Masking), and has no hop count limitation unlike RIP’s 15-hop maximum.
63. What is the main difference between OSPF and RIP routing protocols?
- RIP uses Dijkstra’s algorithm; OSPF uses Bellman-Ford
- OSPF uses link-state routing with no hop limit; RIP uses distance-vector routing with a 15-hop limit
- RIP is faster to converge than OSPF li>OSPF is only used in home networks; RIP is used in enterprise networks
Answer : B Explanation: RIP (Routing Information Protocol) is a distance-vector protocol that uses hop count as its metric, with a maximum of 15 hops — making it unsuitable for large networks. It is slow to converge. OSPF (Open Shortest Path First) is a link-state protocol that uses cost (based on bandwidth) as its metric, has no hop count limit, and converges much faster. OSPF is preferred for modern enterprise networks.
64. What is BGP (Border Gateway Protocol) used for?
- Routing traffic within a single company network
- Routing traffic between different autonomous systems on the internet
- Assigning IP addresses to hosts automatically
- Encrypting data between two border routers
Answer : B Explanation: BGP (Border Gateway Protocol) is the routing protocol that powers the internet. It is an exterior gateway protocol used to exchange routing information between different autonomous systems (AS) — essentially between different organizations or ISPs. BGP is called the “protocol of the internet” because it manages how data is routed across the global internet. It operates on port 179.
65. What is the function of the Session Layer in the OSI model?
- To encrypt and decrypt data for secure transmission
- To establish, manage, and terminate communication sessions between applications
- To convert data into a format suitable for transmission
- To provide physical transmission of raw bits over a medium
Answer : B Explanation: The Session Layer (Layer 5) is responsible for establishing, maintaining, synchronizing, and terminating communication sessions between two applications. It manages dialog control (who can send data and when) and provides checkpointing for long data transfers so sessions can be resumed after a failure. Examples of session layer protocols include NetBIOS and RPC (Remote Procedure Call).
66. What does the Presentation Layer do in the OSI model?
- It routes packets between networks
- It translates, encrypts, and compresses data for the application layer
- It establishes physical connections between devices
- It manages flow control between sender and receiver
Answer : B Explanation: The Presentation Layer (Layer 6) acts as a translator between the application layer and the network. It is responsible for data translation (e.g., converting EBCDIC to ASCII), encryption and decryption (SSL/TLS operates here), and data compression. It ensures that data sent by one system’s application layer can be read by another system’s application layer regardless of format differences.
67. What is the difference between a public IP address and a private IP address?
- Private IP addresses are faster than public IP addresses
- Public IP addresses are routable on the internet; private IP addresses are used within internal networks only
- Public IP addresses are assigned by DHCP; private IP addresses are manually configured
- There is no functional difference between them
Answer : B Explanation: Public IP addresses are globally unique and routable on the internet, assigned by ISPs. Private IP addresses (defined by RFC 1918) are used within internal networks and are not routable on the public internet — they require NAT to communicate externally. Private ranges are 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16.
68. What is the purpose of the TTL (Time to Live) field in an IP packet?
- To define the maximum size of the packet
- To prevent packets from circulating indefinitely by limiting the number of hops
- To specify the time a packet waits in a queue
- To measure the round-trip time of a packet
Answer : B Explanation: TTL (Time to Live) is an 8-bit field in the IP packet header that prevents packets from looping indefinitely in a network. Each router that processes the packet decrements the TTL by 1. When TTL reaches 0, the router discards the packet and sends an ICMP “Time Exceeded” message back to the sender. Common default TTL values are 64 (Linux), 128 (Windows), and 255 (Cisco).
69. Which of the following is a connection-oriented protocol at the Transport layer?
- UDP
- IP
- TCP
- ICMP
Answer : C Explanation: TCP (Transmission Control Protocol) is a connection-oriented protocol at the Transport Layer (Layer 4). Before data is exchanged, TCP establishes a connection through the three-way handshake (SYN, SYN-ACK, ACK). It guarantees reliable, ordered delivery of data and provides error checking, retransmission of lost packets, and flow control. UDP is the connectionless counterpart at the same layer.
70. What is SNMP and what is it used for?
- Simple Network Mail Protocol — used for sending emails
- Simple Network Management Protocol — used for monitoring and managing network devices
- Secure Network Messaging Protocol — used for encrypted messaging
- Standard Network Mapping Protocol — used for creating network maps
Answer : B Explanation: SNMP (Simple Network Management Protocol) is an application layer protocol used to monitor and manage network devices such as routers, switches, servers, and printers. It allows network administrators to collect performance data, detect faults, and configure devices remotely. SNMP operates on UDP port 161 (for queries) and port 162 (for traps/notifications). SNMPv3 is the most secure version, adding authentication and encryption.
