Preparing for technical interviews can be a daunting task, especially when it comes to core subjects like Operating Systems (OS), Database Management Systems (DBMS), and Computer Networks (CN). These topics are essential for any computer science or IT professional and often form the foundation of many interview questions. To help you prepare effectively, this article provides a comprehensive collection of over 50+ key interview questions across OS, DBMS, and CN.
These questions will help you refresh your knowledge, understand core concepts, and practice your problem-solving skills. From basic definitions to more complex scenarios, this guide covers the most important and frequently asked questions to ensure you're well-prepared for your next interview.
Operating System Interview Questions
1. What is an Operating System and why is it used?
An Operating System (OS) is system software that manages computer hardware and software resources and provides common services for computer programs. It acts as an intermediary between users and the computer hardware. The purpose of an operating system is to provide an environment in which a user can execute programs conveniently and efficiently.
Why it is used:
- Resource Management: Manages CPU, memory, disk space, and input/output devices.
- User Interface: Provides a user interface (UI), such as a command line or graphical user interface (GUI).
- Task Scheduling: Handles multitasking, allowing multiple programs to run simultaneously.
- Security: Ensures data protection and system security.
- File Management: Organizes and manages files and directories.
2. What is Thrashing?
Thrashing occurs when excessive paging occurs, causing the system to slow down significantly. It happens when the system spends more time swapping data between RAM and disk (virtual memory) than executing actual processes, often due to insufficient memory. This leads to a severe drop in performance as the system constantly tries to manage memory rather than perform useful tasks.
3. What are the differences between process and thread?
A process is an independent program in execution with its memory and resources, and a thread is the smallest segment of a process that shares memory and resources with other threads in the same process. Processes are heavier and have higher overhead, requiring inter-process communication (IPC) to interact. Threads are lightweight, faster to create, and can communicate easily within the same process since they share the same memory space.
4. What is paging and why do we need it? What is demand paging?
Paging is a memory management scheme that divides physical memory into fixed-sized blocks called pages and logical memory into blocks of the same size called page frames. It helps in efficiently utilizing memory by allowing non-contiguous memory allocation, thus avoiding fragmentation. We need paging to make better use of memory, allowing processes to use memory that may not be contiguous, and to provide each process with its own address space, ensuring isolation and security.
Demand paging is a technique where a page is only loaded into memory when needed, rather than loading the entire process at once. This helps save memory and improves performance by loading only the pages that are actively being used, reducing the time and resources required to load a program.
5. What are the different Scheduling Algorithms?
Scheduling algorithms are methods used by the operating system to determine the order in which processes are executed by the CPU. These algorithms help manage process execution, ensuring efficient CPU utilization and process management.
Types of Scheduling Algorithms:
- First-Come, First-Served (FCFS): The process that arrives first is executed first, without preemption.
- Shortest Job Next (SJN): The process with the smallest execution time is selected next.
- Round Robin (RR): Each process is assigned a fixed time slice, and execution is rotated among processes.
- Priority Scheduling: Processes are assigned a priority, and the one with the highest priority is executed first.
- Shortest Remaining Time First (SRTF): A preemptive version of SJN, where the process with the shortest remaining time is executed next.
- Multilevel Queue Scheduling: Processes are divided into queues based on priority or other factors, and each queue has its own scheduling algorithm.
To know more about the topic refer to CPU Scheduling in Operating Systems
6. What is the difference between logical and physical memory?
Logical memory refers to the address space that a program uses, which is independent of the physical hardware. It’s the memory the program sees and interacts with, typically managed by the operating system using virtual memory. Physical memory, on the other hand, refers to the actual RAM (hardware memory) installed on the system. It’s where data is physically stored and accessed by the computer’s CPU.
In summary, logical memory is the abstracted address space used by programs, while physical memory is the real hardware memory where data is stored.
7. What is Belady's Anomaly?
Belady's Anomaly is a situation where increasing the number of page frames in memory leads to more page faults, which goes against the usual expectation that more memory reduces page faults. This anomaly occurs in certain page replacement algorithms, like FIFO.
To know more about the topic refer to Belady's Anomaly
8. What is Banker's Algorithm?
Banker's Algorithm is a deadlock avoidance algorithm used in operating systems to allocate resources to processes in a safe manner. It determines whether a process can be granted a resource request by checking if the system will remain in a "safe state" after the request is granted. A safe state is one where there is at least one sequence of processes that can complete without causing a deadlock.
To know more about the topic refer to Banker’s Algorithm in Operating System
9. What is Fragmentation? What are the different types of Fragmentation?
Fragmentation refers to the condition where memory is inefficiently utilized due to the allocation and deallocation of memory in varying sizes. Over time, this can lead to gaps or small unusable blocks of free memory, making it difficult to allocate large contiguous blocks of memory to processes, even though the total free memory may appear sufficient.
Types of Fragmentation:
- External Fragmentation: Occurs when free memory is scattered in small, non-contiguous blocks, preventing large enough blocks for new processes despite having enough total free memory.
- Internal Fragmentation: Happens when allocated memory exceeds the memory requested by a process, leaving unused space within the allocated block.
10. What is Spooling?
Spooling (Simultaneous Peripheral Operations On-Line) is a process in which data is temporarily stored in a buffer or queue before being sent to an output device, like a printer or disk, for processing. This allows the CPU to continue executing other tasks while the peripheral device processes the data in the background. Essentially, spooling helps manage data efficiently by handling the queuing and scheduling of output operations, ensuring that multiple processes can be handled without conflict.
11. What are the Classic Synchronization Problems?
Classic synchronization problems are common issues in concurrent programming where multiple processes or threads need to access shared resources without causing data inconsistencies or conflicts. These problems highlight the challenges of synchronizing access to shared data and ensuring correct behavior in multi-threaded or multi-process systems.
Types of Classic Synchronization Problems:
- The Producer-Consumer Problem: A producer generates data and a consumer consumes it. The challenge is to ensure the producer doesn't overwrite data before the consumer processes it, and vice versa.
- The Reader-Writer Problem: Multiple readers can access the resource simultaneously, but writers need exclusive access. The challenge is to balance access between readers and writers without causing data inconsistencies.
- The Dining Philosophers Problem: A scenario where multiple philosophers need two forks to eat. The challenge is to avoid deadlock and ensure no philosopher starves due to resource contention.
- The Sleeping Barber Problem: A barber serves customers in a barber shop. The challenge is to synchronize the barber and customers in such a way that no customer is left waiting indefinitely and the barber doesn’t sit idle if there are customers.
To know more about the topic refer to Classical Problems of Synchronization with Semaphore Solution
12. What is the difference between Multitasking and Multiprocessing?
Multitasking and multiprocessing are both techniques used to execute multiple tasks simultaneously, but they differ in how they utilize system resources.
- Multitasking refers to the ability of an operating system to manage multiple tasks (processes or threads) at once. It gives the illusion of parallelism by rapidly switching between tasks using a single processor. There are two types: preemptive multitasking (where the OS controls the switching) and cooperative multitasking (where tasks yield control voluntarily).
- Multiprocessing, on the other hand, involves using two or more processors (or cores) to execute multiple tasks simultaneously. Each processor can run a different task, achieving true parallelism and significantly improving performance for compute-heavy applications.
13. What is Starvation and Aging in OS?
Starvation happens when a process keeps getting ignored and never gets a chance to run because other processes are always prioritized.
Aging is a method used to prevent starvation, where the waiting process's priority is slowly increased over time, making sure it eventually gets a chance to run.
14. What is Semaphore and Mutex?
A semaphore is a synchronization tool used to control access to shared resources by multiple processes. It has a counter that represents the number of available resources, and processes can signal or wait based on that value. A mutex (mutual exclusion) is a lock that ensures only one thread or process can access a resource at a time. Unlike semaphores, mutexes have ownership, meaning only the thread that locked the mutex can unlock it. The main difference is that semaphores can manage multiple resources, while mutexes provide exclusive access to a single resource.
15. What is RAID? What are the different RAID levels?
RAID (Redundant Array of Independent Disks) is a technology that combines multiple physical disk drives into a single logical unit to improve performance, data redundancy, or both. RAID is used to ensure better data reliability, faster data access, and improved storage capacity. RAID has different levels:
- RAID-0 (Stripping)
- RAID-1 (Mirroring)
- RAID-2 (Bit-Level Stripping with Dedicated Parity)
- RAID-3 (Byte-Level Stripping with Dedicated Parity)
- RAID-4 (Block-Level Stripping with Dedicated Parity)
- RAID-5 (Block-Level Stripping with Distributed Parity)
- RAID-6 (Block-Level Stripping with two Parity Bits)
To know more about the topic refer to RAID
16. Explain Address Binding. What are the different types of Address Binding?
Address binding is the process of mapping a logical address (used by a program) to a physical address (in memory) during the execution of a program. This is necessary for the system to access data and instructions in the correct locations in physical memory.
Types of Address Binding:
- Compile-Time Binding: The address is determined and fixed when the program is compiled. The program must run at the same memory location each time.
- Load-Time Binding: The address is determined when the program is loaded into memory, allowing the program to be loaded at different memory locations each time it runs.
- Execution-Time Binding: The address is determined during the program's execution, allowing for dynamic address changes, such as in the case of virtual memory.
17. What is cache?
A cache is a small, high-speed memory storage used to temporarily store frequently accessed data or instructions. It helps improve the performance of a system by reducing the time it takes to retrieve data from slower memory, like RAM or disk. Caches are typically used in CPUs, disk storage, and web browsers to speed up data access.
18. What are the different kinds of operations possible on semaphore?
The process of using Semaphores provides two operations:
- wait (P): The wait operation decrements the value of the semaphore.
- signal (V): The signal operation increments the value of the semaphore.
19. Explain zombie process?
A zombie process is a process that has completed its execution but still remains in the process table because its parent process has not yet read its exit status. It is called a “zombie” because it is no longer active or running, but it still exists as a placeholder in the system. Zombie processes do not consume system resources like CPU or memory, but they can clutter the process table if not handled properly, especially if many zombie processes accumulate.
20. What is a process? What are the different states of a process?
Process is basically a program under execution. When a program is loaded into memory, it becomes a process and is divided into four sections: stack, heap, text, and data.
States of Process:
States of a ProcessDifferent states of the process through which process goes are given below:
- New State: In this state, a process is just created.
- Running: In this state, the CPU starts working on the process’s instructions.
- Waiting: In this state, the process cannot run because it just waits for some event to occur
- Ready: In this state, the process has all resources available that are required to run but it waits to get assigned to a processor because CPUs are not working currently on instructions passed by the process.
- Terminate: In this state, the process is completed I.e., the process has finished execution.
21. What is a deadlock in OS? What are the necessary conditions for a deadlock?
Deadlock is a situation in computing where two or more processes are blocked because each process is waiting for the resources held by other processes, creating a cycle of dependencies with no way out. In this state, the processes are stuck and cannot continue their execution.
There are basically four necessary conditions for deadlock as given below:
- Mutual Exclusion
- Hold and Wait
- No Pre-emption
- Circular Wait or Resource Wait
22. What is difference between Kernel and OS?
Kernel: Kernel is a system program that controls all programs running on the computer. The kernel is basically a bridge between the software and hardware of the system.
Operating System: Operating system is a system program that runs on the computer to provide an interface to the computer user so that they can easily operate on the computer
Database Management System Interview Questions
23. What is DBMS? What are the advantages of DBMS over traditional file-based systems?
DBMS (Database Management System) is software that manages databases, allowing users to store, retrieve, and manipulate data efficiently. It provides an interface between users and databases, ensuring data is organized, secure, and easily accessible.
Advantages of DBMS over traditional file-based systems:
- Data redundancy and inconsistency
- Difficulty in accessing data
- Data isolation – multiple files and formats
- Integrity problems
- Atomicity of updates
- Concurrent access by multiple users
- Security problems
24. What is RDBMS and what are the advantages?
RDBMS (Relational Database Management System) is a type of DBMS that stores data in a structured format using rows and columns, typically in tables. It uses Structured Query Language (SQL) for managing and manipulating relational data. Examples of RDBMS include MySQL, PostgreSQL, and Oracle.
Advantages of RDBMS:
- Data Integrity: RDBMS enforces integrity constraints (e.g., primary keys, foreign keys) to maintain accurate and consistent data.
- Data Redundancy Control: It minimizes data duplication by organizing data into related tables, reducing redundancy.
- Flexibility and Scalability: RDBMS can handle large volumes of data efficiently, supporting complex queries and large datasets.
- Ease of Access: With SQL, users can easily retrieve, update, and manipulate data in a consistent and standardized way.
- Data Security: RDBMS provides robust security features like user access control and encryption to protect sensitive data.
- Backup and Recovery: RDBMS supports backup and recovery mechanisms to ensure data can be restored in case of system failure.
- Concurrency Control: Multiple users can access and modify the data concurrently without conflicts or data inconsistency.
25. What is the difference between Horizontal and Vertical Scaling?
Horizontal scaling (scaling out) involves adding more machines or servers to distribute the load, increasing system capacity by expanding across multiple nodes. Vertical scaling (scaling up) involves adding more resources (like CPU, RAM, or storage) to a single machine, improving its performance. The main difference is that horizontal scaling adds more systems, while vertical scaling upgrades a single system’s capabilities.
To know more about the topic refer to Horizontal and Vertical Scaling In Databases
26. What are different types of keys in DBMS?
In a DBMS, keys are used to uniquely identify records and establish relationships between tables. They are essential for ensuring data integrity and efficient data retrieval.
Types of Keys:
- Primary Key: A field or combination of fields that uniquely identifies each record in a table. It cannot have NULL values.
- Foreign Key: A field in one table that links to the primary key of another table, establishing a relationship between them.
- Candidate Key: A set of attributes that can uniquely identify a record, from which one is chosen as the primary key.
- Unique Key: A field or combination of fields that ensures all values in a column are unique, but unlike the primary key, it can accept NULL values.
- Composite Key: A key made up of two or more attributes to uniquely identify a record in a table.
- Superkey: A set of attributes that uniquely identifies a record in a table, which may include unnecessary attributes. Every primary key is a superkey, but not every superkey is a primary key.
- Alternate Key: A candidate key that was not chosen as the primary key but can still uniquely identify records.
27. What are the difference between DDL, DML, and DCL in SQL?
Here’s the updated explanation with query syntax for DDL, DML, and DCL:
1. DDL (Data Definition Language):
Used to define and modify the structure of database objects like tables, views, and schemas.
Common Queries:
CREATE: Defines new database objects.
CREATE TABLE table_name (
column1 datatype,
column2 datatype,
...
);
ALTER: Modifies an existing database object.
ALTER TABLE table_name
ADD COLUMN column_name data_type;
DROP: Deletes a database object.
DROP TABLE table_name;
TRUNCATE: Removes all records from a table but keeps its structure.
TRUNCATE TABLE table_name;
2. DML (Data Manipulation Language):
Used to manage and manipulate data within the database (insert, update, delete, and retrieve).
Common Queries:
INSERT: Adds new data to a table.
INSERT INTO table_name (column1, column2, ...)
VALUES (value1, value2, ...);
UPDATE: Modifies existing data.
UPDATE table_name
SET column1 = value1, column2 = value2
WHERE condition;
DELETE: Removes data from a table.
DELETE FROM table_name
WHERE condition;
SELECT: Retrieves data from the database.
SELECT column1, column2, ...
FROM table_name
WHERE condition;
3. DCL (Data Control Language):
Used to control access to data and manage permissions.
Common Queries:
GRANT: Assigns new privileges to a user account, allowing access to specific database objects, actions, or functions.
GRANT privilege_type [(column_list)]
ON [object_type] object_name TO user
[WITH GRANT OPTION];
REVOKE: Removes previously granted privileges from a user account, taking away their access to certain database objects or actions.
REVOKE [GRANT OPTION FOR] privilege_type [(column_list)]
ON [object_type] object_name FROM user [CASCADE];
Key Differences:
- DDL deals with creating and modifying the database structure.
- DML deals with adding, updating, retrieving, and deleting data.
- DCL deals with managing permissions and access control for users.
28. What is a Transaction? What are ACID properties?
A transaction in a database is a sequence of operations performed as a single unit of work. It ensures that the database transitions from one consistent state to another. Transactions are crucial in ensuring data integrity, consistency, and reliability, especially in multi-user environments.
ACID Properties
- Atomicity: A transaction is atomic, meaning it is treated as a single, indivisible unit. Either all operations in the transaction are completed successfully, or none are. If an error occurs, the transaction is rolled back to maintain consistency.
- Consistency: The database must always transition from one consistent state to another. After a transaction, the database should remain in a valid state, adhering to all defined rules, constraints, and relationships.
- Isolation: Transactions are isolated from one another. The operations of one transaction are not visible to others until the transaction is completed. This prevents issues like dirty reads, non-repeatable reads, and phantom reads.
- Durability: Once a transaction is committed, its effects are permanent, even if the system crashes. The changes made by a committed transaction are saved to stable storage.
To know more about the topic refer to ACID Properties
29. What is Normalization? What are the different types of normalization?
Normalization is the process of organizing data in a database to reduce redundancy and improve data integrity. It involves dividing a large table into smaller, manageable tables and defining relationships between them to ensure that data is stored efficiently.
Types of Normalization:
- First Normal Form (1NF): Ensures that each column contains only atomic (indivisible) values and that each record is unique.
- Second Normal Form (2NF): Achieved by ensuring that the table is in 1NF and that all non-key attributes are fully dependent on the primary key.
- Third Normal Form (3NF): Ensures that the table is in 2NF and that there are no transitive dependencies (non-key attributes depending on other non-key attributes).
- Boyce-Codd Normal Form (BCNF): A stronger version of 3NF, where every determinant (an attribute that determines another attribute) is a candidate key.
To know more about the topic refer to Normalization in DBMS
30. What is Denormalization?
Denormalization is the process of intentionally introducing redundancy into a database by merging tables or adding redundant data to improve performance, typically for read-heavy applications. While normalization reduces redundancy to ensure data integrity, denormalization may be used to optimize query performance, particularly when complex joins and aggregations are frequently required. Denormalization can speed up data retrieval at the cost of increased storage and potential data anomalies during updates.
31. What is Concurrency Control Protocol (CCP)?
Concurrency Control Protocol (CCP) is used in database systems to manage simultaneous transactions, ensuring data consistency and preventing conflicts like lost updates or temporary inconsistencies. Common techniques include:
- Lock-based protocols: locking data to prevent conflicts
- Timestamp-based protocols: enforcing transaction order
- Optimistic concurrency control: allowing transactions to execute without locks but checking for conflicts before committing
- Multiversion concurrency control (MVCC): using multiple versions of data to avoid conflicts
These protocols help maintain the ACID properties and ensure safe transaction execution.
32. Explain ER-Model?
The Entity-Relationship (ER) Model is a conceptual framework used to design databases by representing entities (objects) and their relationships. Key components include entities (real-world objects like a person or product), attributes (properties of entities), and relationships (associations between entities). The model uses primary keys to uniquely identify entities and defines cardinality (the number of associations between entities, such as one-to-one, one-to-many, or many-to-many). ER diagrams visually represent these elements to help organize and structure data efficiently.
33. What is a JOIN? What are the different types of JOIN?
A JOIN in SQL is used to combine data from two or more tables based on a related column between them. It allows retrieving data that is spread across multiple tables by linking them through their relationships.
Types of JOINs:
INNER JOIN: Returns only the rows that have matching values in both tables. If there is no match, the row is excluded.
SELECT * FROM table1
INNER JOIN table2 ON table1.id = table2.id;
LEFT JOIN (or LEFT OUTER JOIN): Returns all rows from the left table, and the matching rows from the right table. If there is no match, NULL values are returned for the right table's columns.
SELECT * FROM table1
LEFT JOIN table2 ON table1.id = table2.id;
RIGHT JOIN (or RIGHT OUTER JOIN): Returns all rows from the right table, and the matching rows from the left table. If there is no match, NULL values are returned for the left table's columns.
SELECT * FROM table1
RIGHT JOIN table2 ON table1.id = table2.id;
FULL JOIN (or FULL OUTER JOIN): Returns all rows when there is a match in either left or right table. If there is no match, NULL values are returned for non-matching columns from either table.
SELECT * FROM table1
FULL JOIN table2 ON table1.id = table2.id;
CROSS JOIN: Returns the Cartesian product of both tables, meaning all possible combinations of rows from both tables. It doesn't require a condition to join the tables.
SELECT * FROM table1
CROSS JOIN table2;
Each type of JOIN serves different purposes depending on how you want to combine the data from multiple tables.
34. What is Data Abstraction? What are the different levels of data abstraction?
Data abstraction is the process of hiding the complex details of data storage and providing a simplified interface for users to interact with the data. It is achieved through different levels:
- Physical Level: Describes how data is stored on the hardware (disk, memory) and focuses on storage details.
- Logical Level: Describes the structure of the data, such as tables and relationships, without worrying about physical storage.
- View Level: Provides different user-specific views of the data, ensuring users only see relevant information.
This abstraction helps in simplifying database management and user interaction.
35. What are the differences between DROP, TRUNCATE and DELETE commands?
DROP removes an entire table or database object, including its structure and data, and cannot be rolled back. TRUNCATE removes all rows from a table but keeps the structure intact, and is faster than DELETE. DELETE removes specific rows based on a condition and can be rolled back, but is slower as it logs individual row deletions.
36. Explain Entity, Entity Type, and Entity Set in DBMS?
In DBMS, the concepts of Entity, Entity Type, and Entity Set are fundamental for understanding the structure and organization of data.
- Entity: An entity is a real-world object or concept that is distinguishable from other objects. It can be a person, place, thing, or event that has a distinct existence in the context of a database. For example, a "Student" or "Car" could be entities.
- Entity Type: An entity type defines a category or class of entities that share common properties or attributes. It is a blueprint for creating entities. For example, "Student" can be an entity type, with attributes like Student ID, Name, and Date of Birth.
- Entity Set: An entity set is a collection of similar entities that share the same entity type. For instance, the set of all students in a university would form an "Entity Set" of the entity type "Student."
37. What are the different types of relationships in the DBMS?
In a DBMS, relationships define how entities are connected to each other. There are three main types of relationships based on how entities interact within the database:
- One-to-One: In this relationship, each entity in one table is associated with exactly one entity in another table.
- One-to-Many: In this relationship, one entity in a table is associated with multiple entities in another table, but each entity in the second table is related to only one entity in the first table.
- Many-to-Many: In this relationship, multiple entities in one table are associated with multiple entities in another table. It often requires a junction table to establish the relationship.
These relationships help organize how data in different tables is connected and ensure referential integrity within the database.
38. What is lock? What is the difference between shared lock and exclusive lock?
A lock in a database is a mechanism that ensures controlled access to resources during transactions, preventing conflicts like data inconsistency or lost updates. There are two main types of locks: Shared Lock and Exclusive Lock.
- Shared Lock: Allows multiple transactions to read a resource simultaneously but prevents any transaction from modifying it. This means many transactions can read the same data, but none can alter it until the shared lock is released.
- Exclusive Lock: Gives a transaction the ability to both read and modify a resource, while preventing any other transaction from accessing or altering the data, even for reading, until the lock is released. Therefore, while a shared lock supports concurrent reading, an exclusive lock ensures exclusive access to a resource for a transaction.
39. What are aggregate functions in SQL?
Aggregate functions perform calculations on a set of values and return a single value. Common aggregate functions include:
- COUNT(): Returns the number of rows.
- SUM(): Returns the total sum of values.
- AVG(): Returns the average of values.
- MIN(): Returns the smallest value.
- MAX(): Returns the largest value.
40. What is the difference between UNION and UNION ALL?
- UNION: Removes duplicate rows from the result set, ensuring only unique rows are returned.
- UNION ALL: Includes all rows from each query, including duplicates.
- Performance-wise,
UNION ALL
is faster because it doesn’t require an additional step to remove duplicates.
To read more about SQL Interview Questions, Refer Here.
Computer Networks Interview Questions
41. What is Network? What are the types of Networks (LAN, WAN, MAN)?
A network is a system of interconnected devices that allows sharing of data and resources.
Types of Networks:
- LAN (Local Area Network): Covers a small area like a building or office, enabling fast data sharing among devices within proximity.
- WAN (Wide Area Network): Spans a large geographical area, connecting multiple LANs across cities, countries, or continents, often using the internet.
- MAN (Metropolitan Area Network): Covers a city or large campus, connecting multiple LANs within a metropolitan area.
42. What is Network Topology? What are the types of Network Topology?
Network topology refers to the physical or logical arrangement of devices (like computers, routers, switches) and their connections within a network. It defines how devices are connected and how data flows between them, impacting network performance, management, and reliability.
Types of Network Topology:
- Bus Topology: All devices are connected to a single central cable (the bus). Data sent by one device is available to all other devices, but only the intended recipient receives it. It's simple but can become slow with many devices.
Bus Topology- Star Topology: All devices are connected to a central hub or switch. Data from one device passes through the hub to reach others. It's easy to manage and troubleshoot but depends on the central device for operation.
Star Topology- Ring Topology: Devices are connected in a circular fashion. Data travels in one direction around the ring until it reaches the destination. It's efficient but a failure in any part of the ring can disrupt the entire network.
Ring Topology- Mesh Topology: Every device is connected to every other device, ensuring high redundancy and reliability. It offers fault tolerance but can be complex and expensive to set up.
Mesh Topology- Hybrid Topology: A combination of two or more different topologies to leverage their advantages. For example, combining star and bus topologies.
Hybrid Topology- Tree Topology: A variation of star topology where groups of star-configured networks are connected to a central bus. It allows hierarchical data organization and is scalable.
Tree Topology43. What is TCP Model?
The TCP Model (Transmission Control Protocol Model), also known as the TCP/IP model, is a conceptual framework used to understand how different protocols work together to enable communication over a network, especially the internet. It is a four-layer model that standardizes the functions required for communication in computer networks.
- Application Layer: Manages network services for applications (e.g., HTTP, FTP, SMTP).
- Transport Layer: Ensures reliable data transfer (e.g., TCP, UDP).
- Internet Layer: Handles logical addressing and routing (e.g., IP).
- Network Interface Layer: Deals with physical data transmission (e.g., Ethernet, Wi-Fi).
To know more about the topic refer to TCP Model.
44. What is OSI Model? What are the different layers of OSI Model?
The OSI Model (Open Systems Interconnection Model) is a conceptual framework used to understand and standardize the functions of a network in seven distinct layers. It serves as a reference model for how different network protocols interact and provides a guideline for designing and implementing network systems.
Layers of OSI ModelTo know more about the topic refer to OSI Model.
45. What is the difference between OSI and TCP Model?
TCP/IP | OSI |
---|
TCP refers to Transmission Control Protocol. | OSI refers to Open Systems Interconnection. |
TCP/IP uses both the session and presentation layer in the application layer itself. | OSI uses different session and presentation layers. |
TCP/IP follows connectionless a horizontal approach. | OSI follows a vertical approach. |
The Transport layer in TCP/IP does not provide assurance delivery of packets. | In the OSI model, the transport layer provides assurance delivery of packets. |
Protocols cannot be replaced easily in TCP/IP model. | While in the OSI model, Protocols are better covered and are easy to replace with the technology change. |
TCP/IP model network layer only provides connectionless (IP) services. The transport layer (TCP) provides connections. | Connectionless and connection-oriented services are provided by the network layer in the OSI model. |
46. What is the difference between gateway and router?
A router connects multiple networks and routes data between them based on IP addresses, typically within similar networks like LANs and WANs. A gateway, on the other hand, connects different types of networks (often with different protocols) and translates data between them, allowing communication across diverse systems. While routers manage data traffic within a network, gateways provide access and translation between different network architectures.
47. What is MAC Address?
A MAC address is a unique identifier assigned to a network device's hardware (NIC) for communication within a local network. It is a 48-bit address used at the data link layer (Layer 2) to ensure correct data delivery between devices.
48. What is the difference between hub and switch?
A hub is a basic networking device that broadcasts data to all connected devices, regardless of the intended recipient, which can lead to collisions and reduced efficiency. A switch, on the other hand, intelligently forwards data only to the specific device it is intended for, improving network performance and reducing collisions.
49. What is the difference between IPv4 and IPv6 Protocols?
IPv4 (Internet Protocol version 4) uses 32-bit addresses, allowing for about 4.3 billion unique addresses. It is widely used but limited in address space. IPv6 (Internet Protocol version 6) uses 128-bit addresses, providing a virtually unlimited number of unique addresses, and it also includes enhanced features like better security and more efficient routing.
To know more about the topic refer to IPv4 and IPv6
50. Explain the concept of IP addressing and subnetting.
IP addressing is the system that assigns a unique numerical identifier (IP address) to each device on a network, allowing them to communicate. IP addresses are divided into two types: IPv4 (32-bit) and IPv6 (128-bit).
Subnetting is the process of dividing a larger IP network into smaller, manageable sub-networks (subnets). This improves network performance, security, and IP address utilization by allocating different ranges of IP addresses to different segments of a network. Subnetting involves using subnet masks to identify the network and host portions of an IP address.
To know more about this topic refer to IP addressing and Subnetting
51. What is 3-Way Handshaking?
3-way handshaking is a process used in the TCP protocol to establish a reliable connection between a client and a server. This process ensures both sides are ready for data transmission. It involves three steps:
- SYN: The client sends a synchronization (SYN) message to the server to initiate the connection.
- SYN-ACK: The server responds with a synchronization-acknowledgment (SYN-ACK) message, confirming the connection request.
- ACK: The client sends an acknowledgment (ACK) message back to the server, completing the connection setup.
To know more about the topic refer to 3 way handshaking
52. What is HTTP and HTTPS protocol?
HTTP (Hypertext Transfer Protocol) is a protocol used for transferring data over the web. It defines how messages are formatted and transmitted between a client (like a browser) and a server. However, it is not secure, meaning data is transmitted in plain text.
HTTPS (Hypertext Transfer Protocol Secure) is the secure version of HTTP. It uses SSL/TLS encryption to secure the data transfer, ensuring confidentiality and data integrity between the client and server, preventing unauthorized access or tampering with the data.
53. What are the differences between TCP and UDP protocols?
TCP (Transmission Control Protocol) is a reliable, connection-oriented protocol that ensures data is delivered accurately. It establishes a connection with a 3-way handshake and uses error-checking, acknowledgments, and retransmissions to guarantee correct delivery. This makes TCP suitable for applications like web browsing (HTTP) and file transfers (FTP), but it is slower due to its overhead.
UDP (User Datagram Protocol) is a connectionless and faster protocol that prioritizes speed over reliability. It does not establish a connection or guarantee data delivery, making it suitable for real-time applications like video streaming, online gaming, and VoIP calls, where speed is more important than perfect accuracy.
To know more about the topic refer to TCP and UDP Protocols
54. What are the different types of delays?
Delay in networking refers to the time it takes for data to travel from the source to the destination. There are several types of delays that can affect network performance:
- Propagation Delay: The time it takes for a signal to travel from the sender to the receiver through the transmission medium, dependent on the distance and the speed of the medium.
- Transmission Delay: The time required to push all the data packets onto the link, determined by the size of the packet and the bandwidth of the link.
- Processing Delay: The time taken by network devices (routers, switches) to process data, check for errors, and make routing decisions.
- Queuing Delay: The time data spends in queues at routers or switches when the network is congested or when there is high traffic. This delay varies depending on the network load.
To know more about the topic refer to Different Types of Delays
55. What is VPN? What are the advantages and disadvantages of VPN?
A VPN (Virtual Private Network) is a service that creates a secure and encrypted connection over a public network (like the internet), allowing users to send and receive data privately and securely as if they were on a private network.
Advantages:
- Enhanced Security: Encrypts data, protecting it from hackers and eavesdropping.
- Privacy: Hides your IP address, ensuring anonymity while browsing.
- Access to Restricted Content: Allows access to region-restricted websites and services.
Disadvantages:
- Reduced Speed: Encryption and routing through VPN servers can slow down internet speed.
- Cost: Quality VPN services often require a subscription fee.
- Complexity: Setting up and configuring a VPN can be complicated for some users.
To know more about the topic refer to VPN (Virtual Private Network) .
56. What does ping command do?
Ping (Packet Internet or Inter-Network Groper) is a basic internet command that is used to check the connectivity, reachability between IP-networked devices.
To know more about the topic refer to Ping command.
57. What is the SMTP Protocol?
SMTP (Simple Mail Transfer Protocol) is a protocol used for sending and relaying emails across networks. It defines the rules for how email messages are sent from the sender's email client to the mail server and then to the recipient's mail server. SMTP operates on a client-server model, typically using port 25, and ensures the reliable delivery of email messages over the internet.
To know more about the topic refer to SMTP Protocol
58. What happens when you enter "google.com"?
When you enter "google.com" in your browser, several steps happen to connect you to the website:
- DNS Lookup: The browser checks if the domain name "google.com" has a corresponding IP address by querying a DNS (Domain Name System) server. The DNS server returns the IP address of Google's web server.
- TCP/IP Connection: Using the IP address, the browser establishes a connection to Google's server using the TCP/IP protocol (via port 80 for HTTP or port 443 for HTTPS).
- HTTP/HTTPS Request: The browser sends an HTTP/HTTPS request to the server, asking for the webpage.
- Server Response: Google's server processes the request and sends back the requested data (HTML, CSS, JavaScript, images, etc.) via the same connection.
- Rendering: The browser processes the data, rendering the webpage so that you can see and interact with google.com.
59.What is an IPv4 address? What are the different classes of IPv4?
An IP address is a 32-bit dynamic address of a node in the network. An IPv4 address has 4 octets of 8-bit each with each number with a value up to 255.
IPv4 classes are differentiated based on the number of hosts it supports on the network. There are five types of IPv4 classes and are based on the first octet of IP addresses which are classified as Class A, B, C, D, or E.
Classes In IP Addressing60.What is DNS?
DNS stands for Domain Name System. It translates domain names into IP addresses, which are used by browsers to load web pages. Example: Human-readable domain names like www.google.com into machine-readable IP addresses such as 142.250.190.14.
To know more about the topic refer to DNS.
Must Read:
Conclusion
Mastering the core concepts of Operating Systems (OS), Database Management Systems (DBMS), and Computer Networks (CN) is essential for excelling in technical interviews. The 50+ interview questions presented in this article provide a well-rounded review of these topics, helping you sharpen your understanding and boost your confidence. By revisiting key concepts, and familiarizing yourself with common interview patterns, you'll be better equipped to tackle a wide range of questions during your interview. This article aims to be a helpful resource in your journey to securing your dream job. Good luck!
Similar Reads
Technical Interview Questions - A Complete 2024 List
Technical interviews are a crucial part of the hiring process for many tech companies like Amazon, Microsoft, Cisco, Google, Facebook, etc. as they test your technical skills, knowledge, and problem-solving abilities. The purpose of a technical interview is to test how you solve real-world problems,
5 min read
Top HR Interview Questions and Answers (2025)
HR interviews can be daunting but they donât have to be. The bottom line in most hiring processes entails testing the personality of a candidate for their communication traits and company culture fit. Being at the initial or experienced levels of your career being prepared for commonly asked fresher
15+ min read
Top Low-Level Design(LLD) Interview Questions 2024
Low-Level Design (LLD) is a crucial phase in software development that involves turning high-level architectural designs into implementable modules. In this post, we will look into the top 20 commonly asked interview questions on the low-level design. Table of Content What is the purpose of Low-Leve
8 min read
Top Desktop Support Engineer Interview Questions [2025]
Desktop Support Engineer Interview Questions - Desktop Support Engineer interviews for freshers often focus on troubleshooting basics, OS knowledge, and customer service skills. Experienced candidates are tested on advanced areas like Active Directory, remote troubleshooting, and network diagnostics
15+ min read
50+ Common Job Interview Questions and Answers
Common Interview Questions: Preparing for a job interview can be daunting, but being well-prepared can significantly boost your confidence and chances of success. To help you ace your next interview, here is a list of the Top 50 common interview questions for freshers/college students or experienced
15+ min read
Amdocs Interview Questions
Amdocs is a global leader in software and services for communications, media, and financial services providers that stands at the forefront of technological transformation. Their solutions empower businesses to navigate the rapidly evolving digital landscape, optimize operations, and deliver seamles
5 min read
TCS Digital Interview Questions
After the Online National Qualifier Test for TCS Digital, interviews were conducted on TCS premises. My interview went roughly till 75 mins. When I introduced myself, they said that I should mention something that I have not mentioned in my CV. They asked for my favorite subjects and also about the
4 min read
Advanced SQL Interview Questions
Mastering advanced SQL is always important if you are preparing for data-centric job roles. SQL (Structured Query Language) is the backbone of database management, and employers look for candidates who can show they understand advanced SQL concepts. This interview preparation guide covers frequently
4 min read
Operating System Interview Questions
An operating system acts as a GUI between the user and the computer system. In other words, an OS acts as an intermediary between the user and the computer hardware, managing resources such as memory, processing power, and input/output operations. Here some examples of popular operating systems incl
15+ min read
Top 25 Frequently Asked Interview Questions in Technical Rounds
Here is the collection of the TOP 25 frequently asked questions based on the experience of interviews in multiple companies. 1Lowest common Ancestor2An unsorted array of integers is given; you must find the max product formed by multiplying three numbers. (You cannot sort the array, watch out when t
1 min read