0% found this document useful (0 votes)
134 views11 pages

22516-Practice Test Unit 1 2

Uploaded by

pranav25shahane
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
134 views11 pages

22516-Practice Test Unit 1 2

Uploaded by

pranav25shahane
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Q. N 1 Attempt All of the following.

(marks 14*2)

1. What is operating system? Define.


An Operating System (OS) is system software that manages computer hardware, software resources,
and provides common services for computer programs. It acts as an intermediary between users
and the computer hardware, facilitating the execution of programs efficiently.
2. What are components of Operating system?
Process management
Memory management
File management
device management
Protection and security
User interface or command interpreter
Booting the computer
Performs basic computer tasks
3. What are the different views of Operating System?
Different views of an operating system are
1. application view
2. user view
3. system view
4. implementation view
4. Differentiate between MS DOS OS and Windows OS.

MS-DOS Windows OS

Command-Line Interface (CUI). Graphical User Interface (GUI).

Single-tasking. Multi-tasking, allowing multiple applications to run.

Requires manual input for tasks. User-friendly with visual icons and windows.

Supports 16-bit operations. Supports 32-bit and 64-bit operations.

Limited memory management. Advanced memory management with virtual memory.

5. What are different types of operating system?


• Batch Operating System: Processes jobs in batches without user interaction.
• Time-Sharing Operating System: Allows multiple users to access the system
simultaneously.
• Distributed Operating System: Manages a group of independent computers and makes
them appear to be a single system.
• Real-Time Operating System (RTOS): Provides immediate processing and response to
events, used in systems that require timely processing (e.g., embedded systems, medical
devices).
• Multi-tasking/Multi-user Operating System: Allows multiple tasks or users to share the
system simultaneously (e.g., Windows, UNIX).

6. Differentiate between GUI and CUI.


GUI (Graphical User Interface) CUI (Character User Interface)
Interaction through graphical elements
Interaction through text commands.
(icons, menus, windows).
Requires knowledge of commands, more difficult for
Easier to use, more user-friendly.
beginners.
Example:
Example: Windows, macOS. MS-DOS,
UNIX.
Allows multitasking with multiple Single-task oriented; users work in one command
windows open. line interface.

7. What is a real time system?

A Real-Time System is a type of operating system that guarantees a certain capability within a specified
time constraint. It is used in environments where time is critical, such as medical systems, robotics, and
embedded systems.

Soft real time operating system and hard real time operating system

8. Name two important services provided by an operating system.

• Process Management: The OS manages the execution of multiple processes, ensuring each
process gets sufficient CPU time.

• Memory Management: The OS efficiently allocates and deallocates memory space to programs,
ensuring optimal memory usage.

9. Define a system call.

A system call is a programmed request from a user-level application to the operating system, allowing it
to request services such as file manipulation, process control, or communication.

10. List two types of system calls.

• Process Control: Example: fork(), exit().

• File Manipulation: Example: open(), read().


11. What is process management in an operating system?

Process Management is the function of the OS that handles the creation, scheduling, execution, and
termination of processes, ensuring efficient CPU utilization and multitasking.

12. Define main memory management.

Main Memory Management is the process by which the OS manages the allocation and deallocation of
the computer's primary memory (RAM) to various programs and processes, ensuring optimal use of
memory resources.

13. What is file management in an OS?

File Management refers to the OS's ability to create, delete, read, write, and organize files on storage
devices, as well as manage file permissions and access control.

14. What is I/O system management in operating systems?

I/O System Management involves managing the input/output devices of a computer, including handling
device drivers, buffering, and ensuring data is transferred efficiently between the hardware and
processes.

Q. N 2 Attempt All of the following.

1. Differentiate between distributed OS and network OS.

Distributed OS Network OS

Definition: Manages a group of independent Definition: Allows multiple computers to communicate


computers and makes them appear as a and share resources over a network, but each system is
single system to users. independent and has its own OS.

Resource Management: Resources (CPU, Resource Management: Resources are managed


memory, etc.) are shared across multiple independently by each computer's OS, and shared
systems as if they belong to a single OS. resources are accessed over a network.

Transparency: Provides transparency (location,


Transparency: Users are aware of the location of
access, and replication transparency), meaning
resources and need to access them through a network
users are unaware of where resources or files
interface.
are physically located.

Fault Tolerance: Offers higher fault tolerance, Fault Tolerance: Less fault tolerant because each
as tasks can be shifted from one machine to computer runs independently, and failure of one
another in case of failure. system affects only that system.
Examples: UNIX, Linux (network version), Windows
Examples: Amoeba, Mach, Plan 9.
Server.

2. Differentiate between time sharing OS and Real Time OS.

Time-Sharing OS Real-Time OS (RTOS)

Definition: Provides immediate processing and


Definition: Allows multiple users to share system
response to input or events, with strict timing
resources simultaneously by switching between
constraints, critical in systems where timing is
tasks rapidly, giving the illusion of parallelism.
crucial.

Response Time: Response time is not guaranteed; it Response Time: Response time is guaranteed, and
depends on how the system schedules tasks. tasks must be completed within a fixed time frame.

Task Scheduling: Uses techniques like round-robin Task Scheduling: Uses priority-based or deadline
or priority scheduling to allocate CPU time to scheduling to ensure critical tasks are completed on
multiple tasks. time.

Application: Used in embedded systems, robotics,


Application: Suitable for general-purpose systems military applications, medical devices, and
like time-sharing mainframes, servers, or desktops. industrial control systems where timeliness is
crucial.

Examples: UNIX, Linux, Windows. Examples: VxWorks, FreeRTOS, QNX.

3. Explain multiprogrammed operating systems.

A Multiprogrammed Operating System is an operating system that allows multiple programs to reside in
the system's memory at the same time, improving the overall utilization of the CPU. It maximizes CPU
usage by ensuring that the processor always has something to execute, switching between tasks when
one becomes idle, such as when waiting for I/O operations.

Key Features of Multiprogrammed Operating Systems:

1. Job Scheduling: The OS keeps several jobs in memory simultaneously and selects one of them to
run. When the running job waits for an event (like I/O completion), the OS switches to another
job, ensuring that the CPU is always busy.
2. Efficient CPU Utilization: Instead of keeping the CPU idle during long I/O operations, it switches
to other ready-to-execute jobs. This increases CPU efficiency and ensures that all system
resources are optimally used.

3. Memory Management: Since multiple jobs reside in memory at once, efficient memory
management is essential. The OS must allocate memory to different programs and protect them
from interfering with each other.

4. Context Switching: The OS frequently switches between programs to utilize the CPU efficiently.
This involves saving the state of the current program and loading the state of the next program
to be executed.

Example of Multiprogramming:

Consider a scenario where one program is reading data from a disk while another program is performing
computations. In a multiprogrammed system, while the first program is waiting for the disk read to
complete, the CPU can switch to the second program and start executing its computations. This way, the
CPU isn't wasting time and remains busy.

Advantages:

• Increased Efficiency: The CPU can execute more than one job at a time, reducing idle time and
improving throughput.

• Better Resource Utilization: The system's memory and CPU are used efficiently because multiple
programs share resources.

Disadvantages:

• Complexity: Managing multiple programs and ensuring efficient scheduling can add complexity
to the operating system.

• Memory Requirements: Multiprogramming requires more memory to keep several programs in


memory simultaneously, which might limit the number of jobs that can run.

4. What are the basic file permissions? Explain.

1. Permission Groups

Each file and directory has three user based permission groups:

• Owner: the owner permissions apply only the owner of the file or directory, they will not impact the
actions of other users.
• Group: the group permissions apply only the group that has been assigned to the file or directory,
they will not effect the actions of other users.

• All users: the all users permissions apply to all other users on the system, this is the permission group
that you want to watch the most.

2. permission types

Each file or directory has three basic permission types:

1. Read: the read permission refers to a users capability to read the contents of the file.

2. Write: the write permissions refers to a users capability to write or modify a file or directory.

3. execute: the execute permission affects a users capability to execute a file or view the contents of a
directory.

3. Viewing the permissions

• You can view the permissions by checking the file or directory permission in your favorite GUI file
manager or by reviewing the output of the \”|s |”\ command while in the terminal and while working in
the directory which contains the file or folder.

4. modifying the permissions

When in the command line, the permissions are edited by using the command chmod.

5. Explain user authentication.

Several protection methods are developed by keeping in mind that, the system knows the recognition of
each user. - The user authentication is the method to identify the user while logging into the system. -
Authentication enables organizations to keep their networks secure by permitting only authenticated
users or processes to gain access to their protected resources.

- User authentication types 1. Password 2. Physical identification 3. countmeasures

1. Passwords: username and password is simplest and most commonly used authentication. The
simplest implementation just maintains a central list of login name and password pairs.

2. Physical identification: physical object such as plastic card with magnetic strip on it can be used for
authorization of users. So combination of cards and password is used in this method.

3. Countermeasures: a user should be allowed to login only from specific terminal and fixed time slot of
particular days should be given to each user. in this simple approach, one special login name with an
easy password is used.

6. Explain role of administrator for security.


it is the responsibility of administrator to set access to some of the systems services. Some of the users
need to be protected from accessing some services.

1. Password aging: administrator in the system with /etc/shadow file can enforce the users to change
the password after some predetermined time. Command used for updating the fields with appropriate
options is passwd.

2. Shell Restriction: to control the users activities, administrator set up the user account with a special
restricted shell.

Q. N 3 Attempt All of the following.

1. What is a real time system? Explain in detail.

Real-Time System (RTS) is a computer system that is designed to perform tasks and respond to inputs or
events within a strict time constraint. The key characteristic of a real-time system is its ability to provide
predictable and timely responses to events, ensuring that tasks are completed within a predefined time
limit, known as a deadline.

In real-time systems, missing a deadline can have severe consequences, especially in critical applications
such as medical devices, industrial control systems, or aviation systems, where timing is crucial for the
proper functioning of the system.

Characteristics of a Real-Time System:

1. Deterministic Behaviour:
The system must behave in a predictable manner, where every task has a guaranteed start and
end time. This is vital for time-sensitive operations.

2. Deadline-Driven:
Real-time systems are deadline-oriented. The correctness of an operation depends not only on
the logical correctness of the computation but also on its timeliness.

3. Reliability:
These systems must operate continuously and be highly reliable, as failure to meet deadlines
can lead to critical failures or safety hazards.

4. Concurrency:
Real-time systems often need to handle multiple events concurrently. They must manage and
prioritize tasks so that high-priority tasks are completed first.

5. Task Prioritization:
In real-time systems, tasks are usually assigned priorities. Tasks with higher priority (e.g., tasks
related to safety or urgent requirements) pre-empt lower-priority tasks to ensure timely
execution.

Types of Real-Time Systems:

1. Hard Real-Time Systems:


These systems have strict timing constraints, and missing a deadline is considered catastrophic,
leading to system failure. For example, in an airbag deployment system, failing to deploy at the
exact moment of impact could lead to serious injuries or fatalities.

Examples:

o Pacemakers (medical devices)

o Industrial robots

o Aircraft control systems

2. Soft Real-Time Systems:


In these systems, meeting deadlines is important but not critical. If deadlines are occasionally
missed, the system can still function correctly, though performance may degrade. For example,
in a video streaming system, occasional delays in frame delivery may reduce quality but do not
cause the system to fail.

Examples:

o Video streaming

o Online transaction systems

o Gaming applications

Components of Real-Time Systems:

1. Real-Time Operating System (RTOS):


The OS in a real-time system is designed to manage hardware resources efficiently, prioritize
tasks, and meet timing constraints. The RTOS must support real-time scheduling algorithms that
ensure critical tasks meet their deadlines.

2. Scheduler:
The scheduler determines which task should be executed next, based on task priorities and
deadlines. Scheduling in real-time systems uses algorithms like Rate Monotonic Scheduling
(RMS) or Earliest Deadline First (EDF).

3. Task Management:
The system must manage multiple tasks concurrently, ensuring that tasks do not interfere with
each other, and that high-priority tasks can preempt lower-priority tasks when necessary.
4. Interrupt Handling:
Real-time systems must handle external events (such as sensor inputs) promptly. Interrupts
allow the system to stop the current task, handle the incoming event, and then resume the
interrupted task.

Applications of Real-Time Systems:

1. Embedded Systems:

2. Aerospace and Defense:

3. Industrial Automation:

4. Telecommunications:

Examples of Real-Time Systems:

• Flight Control Systems:

• Medical Monitoring Devices:

• Automotive Systems:

2.Explain the different types of system calls.

Types of System Calls

1. Process control.

2. File management

3. Device management.

4. Information maintenance.

5. Communications.

1.Process control • System call related to process control:-

 End, Abort.

Load, Execute.

Create process, terminate process.

Get process attribute, set process attribute.

wait event , signal event.


Wait for time 

Change the priority of a process.

Allocate and free memory.

2.File management

• System call related to file manipulation: -

 Create a file , delete a file.

Open a file , Close a file.

Create a directory.

Get file attributes, set file attributes.

Read, Write, Reposition.

Create a link.

Change the working directory.

3. Device Management

• It use for managing devices.

Request device, release device.

Read, write, reposition.

Get device attribute, set device attributes.

Logically attach or detach devices

4. Information maintenance

• To do Information maintenance.

Get time or date, set time or date.

Get system data, set system data.

Get process, file, or device attributes.

Set process, file or device attributes.

5. Communications
• For communicating among calls

Create, delete communication connection.

Send, receive messages.

Transfer status information.

Attach or detach remote devices.

4. Explain in short process Management components of operating system.

5. Explain in Main Memory Management components of operating system.

6. Explain in short File Management components of operating system.

✂✂✂✂✂✂✂✂✂✂✂✂☻ALL THE BEST☻✂✂✂✂✂✂✂✂✂✂✂✂✂

You might also like