Anda di halaman 1dari 7

17NU1A0529

1. EXPLAIN IN DETAIL ABOUT OPERATING SYSTEM


SERVIECES

Operating System Services


Operating system services are responsible for the management of platform
resources, including the processor, memory, files, and input and output. They
generally shield applications from the implementation details of the machine.
Operating system services include:

 Kernel operations provide low-level services necessary to:


o create and manage processes and threads of execution
o execute programs
o define and communicate asynchronous events
o define and process system clock operations
o implement security features
o manage files and directories, and
o control input/output processing to and from peripheral devices.
 Some kernel services have analogues described in the paragraph on Object Services, such as
concurrency control services.
 Command interpreter and utility services include mechanisms for services at the operator
level, such as:
o comparing, printing, and displaying file contents
o editing files
o searching patterns
o evaluating expressions
o logging messages
o moving files between directories
o sorting data
o executing command scripts
o local print spooling
o scheduling signal execution processes, and
o accessing environment information.
 Batch processing services support the capability to queue work (jobs) and manage the
sequencing of processing based on job control commands and lists of data. These services also
include support for the management of the output of batch processing, which frequently
includes updated files or databases and information products such as printed reports or
electronic documents. Batch processing is performed asynchronously from the user requesting
the job.
 File and directory synchronization services allow local and remote copies of files and
directories to be made identical. Synchronization services are usually used to update files after
periods of off line working on a portable system.
2. EXPLAIN THE STRUCTURE OF OPERATING SYSTEM AND ITS FUNCTIONS

OPERATING SYSTEM STRUCTURE:

Operating System (OS) is one of the core software programs that runs on the hardware
and makes it usable for the user to interact with the hardware so that they can send
commands (input) and receive results (output). It provides a consistent environment for
other software to execute commands. So we can say that the OS acts at the center
through which the system hardware, other softwares, and the user communicate. The
following figure shows the basic working of the operating system and how it utilizes
different hardware or resources.

Figure: Operating system working as a core part

Operating system serves many functions but I will discuss about the major functions
which all operating systems have.

Basic Functions of the Operating system


The key five basic functions of any operating system are as following

1. Interface between the user and the hardware :

An OS provides an interface between user and machine. This interface can be a


graphical user interface (GUI) in which users click onscreen elements to interact with
the OS or a command-line interface (CLI) in which users type commands at the
command-line interface (CLI) to tell the OS to do things.
Figure: GUI vs CLI

2. Coordinate hardware components :

An OS enables coordination of hardware components. Each hardware device


speaks a different language, but the operating system can talk to them through the
specific translational softwares called device drivers. Every hardware component
has different drivers for Operating systems. These drivers make the
communication successful between the other softwares and the hardware.

Figure: Device Drivers in between OS and Hardware devices

3. Provide environment for software to function:


An OS provides an environment for software applications to function. An
application software is a specific software which is used to perform specific task.
In GUI operating systems such as Windows and macOS, applications run within a
consistent, graphical desktop environment.

4. Provide structure for data management :

An OS displays structure/directories for data management. We can view file and folder
listings and manipulate on those files and folders like (move, copy, rename, delete, and
many others).

5. Monitor system health and functionality:

OS monitors the health of our system’s hardware, giving us an idea of how well (or not)
it’s performing. We can see how busy our CPU is, or how quickly our hard drives retrieve
data, or how much data our network card is sending etc. and it also monitors system
activity for malware.

Figure: Performance Monitor in windows


3. EXPLAI N THE PURPOSE OF SYSTEM CALLS AND DISCUSS THE SYSTEM
CALLS RELATED TO PROCESS CONTROL AND COMMUNICATION IN BREIF

The system call provides an interface to the operating system services.

Application developers often do not have direct access to the system calls, but can
access them through an application programming interface (API). The functions that are
included in the API invoke the actual system calls. By using the API, certain benefits
can be gained:

 Portability: as long a system supports an API, any program using that API can
compile and run.
 Ease of Use: using the API can be significantly easier then using the actual
system call.

System Call Parameters

Three general methods exist for passing parameters to the OS:

1. Parameters can be passed in registers.


2. When there are more parameters than registers, parameters can be stored in a
block and the block address can be passed as a parameter to a register.
3. Parameters can also be pushed on or popped off the stack by the operating
system.
Process Control

A running program needs to be able to stop execution either normally or abnormally.


When execution is stopped abnormally, often a dump of memory is taken and can be
examined with a debugger.

File Management

Some common system calls are create, delete, read, write, reposition, or close. Also,
there is a need to determine the file attributes – get and set file attribute. Many times
the OS provides an API to make these system calls.

Device Management

Process usually require several resources to execute, if these resources are


available, they will be granted and control returned to the user process. These
resources are also thought of as devices. Some are physical, such as a video card,
and others are abstract, such as a file.

User programs request the device, and when finished they release the device. Similar
to files, we can read, write, and reposition the device.

Information Management

Some system calls exist purely for transferring information between the user program
and the operating system. An example of this is time, or date.
The OS also keeps information about all its processes and provides system calls to
report this information.

Communication

There are two models of interprocess communication, the message-passing model


and the shared memory model.

 Message-passing uses a common mailbox to pass messages between


processes.
 Shared memory use certain system calls to create and gain access to create
and gain access to regions of memory owned by other processes. The two
processes exchange information by reading and writing in the shared data.

Anda mungkin juga menyukai