0% found this document useful (0 votes)
4 views

practical of operating system-1

The document provides an overview of single user systems, network operating systems, and multiuser systems, detailing their types, advantages, and disadvantages. It explains user administration in Windows and Linux, including user management tasks and commands for creating and modifying user accounts. Additionally, it includes a program for simulating the FCFS non-preemptive CPU scheduling algorithm to calculate turnaround and waiting times.

Uploaded by

Akriti Thakur
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)
4 views

practical of operating system-1

The document provides an overview of single user systems, network operating systems, and multiuser systems, detailing their types, advantages, and disadvantages. It explains user administration in Windows and Linux, including user management tasks and commands for creating and modifying user accounts. Additionally, it includes a program for simulating the FCFS non-preemptive CPU scheduling algorithm to calculate turnaround and waiting times.

Uploaded by

Akriti Thakur
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/ 10

Practical No: -1

overview of single user system, network operating system and multiuser system

 Single user system: -

Single user operating is that in which one user works on one interface. In these systems
no other operating system is interrupting with the processing. Single user operating
systems work on processing that require less resources. Today we will discuss some of
advantages and disadvantages of these systems.

 Types of single user operating system: -

1) Single Task Operating System: -

In this, only one user can perform a task at a time. This operating system specially
designs for cordless phones and two-way messaging devices. Some functions, such as
printing a document and downloading images and videos, are performed after the idea
is provided.

2) Multitasking Operating System: -

The multitasking operating system specially develops for one user, but that single user
can simultaneously perform multiple tasks. Some examples include typing any text
while browsing the Internet and downloading images while watching movies, etc.

 Advantages: -
1) Therefore, this operating system does not need to support the overhead of requests
from multiple users.
2) Multiple resources do not use in a single operating system, so they are less complex.
For this reason, this operating system is only required for simple maintenance and
debugging.
3) Multiple resources do not use in a single operating system, so they are less complex.
For this reason, this operating system is only required for simple maintenance and
debugging.
4) Multiple resources do not use in a single operating system, so they are less complex.
For this reason, this operating system is only required for simple maintenance and
debugging.
5) The multitasking operating system specially develops for one user, but that single
user can simultaneously perform multiple tasks. Some examples include typing any
text while browsing the Internet and downloading images while watching movies,
etc.

 Disadvantages: -

1) This system cannot optimize CPU, memory, and disk I / O to the optimum level due
to high CPU sleep group demand.
2) It has a high response time.
3) And also, it uses high downtime.
4) And also, it cannot perform multiple tasks simultaneously, so the processor waits for
execution until a job completes.

 network operating system (NOS): -


A network operating system (NOS) is a computer operating system (OS) that's designed
primarily to support workstations, PCs and, in some instances, older terminals that are
connected on a local area network (LAN). The software behind a NOS enables multiple
devices within a network to communicate and share resources with each other. However,
a typical NOS no longer exists, as most OSes have built-in network stacks that support a
client-server model.
 Type of network: -

1) Peer-to-Peer: -
Peer-to-peer networks are network resources where each and every system has the
same responsibilities and capabilities, i.e., no system in this design is more functional
than the others.

2) Client-Server: -
It refers to a server-based network where clients and servers share storage.

2
 Common features of network operating systems: -

1) Printer and application sharing.


2) Common file system and database sharing.
3) Directory services.
4) Directory services.
5) Internetworking.

 Advantages: -

1) Highly stable due to central server.


2) Provide good security.
3) Upgradation of new technology and hardware can be easily implemented in the
network.

 Disadvantages: -

1) Depend on the central location to perform the operations.


2) High cost to buying server.
3) Regular updating and maintenance are required.

 Multi-User Operating System: -

In a multiuser operating system, multiple numbers of users can access different resources
of a computer at the same time. The access is provided using a network that consists of
various personal computers attached to a mainframe computer system. A multi-user
operating system allows the permission of multiple users for accessing a single machine

3
at a time. The various personal computers can send and receive information to the
mainframe computer system. Thus, the mainframe computer acts as the server and other
personal computers act as clients for that server.

 Types of Multi-user Operating Systems: -


The multi-user operating systems is of the following types:
1) Time sliced system
2) Multiprocessor system
3) Distributed System

 Features: -

1) Time-sharing
2) Background sharing
3) Invisibility: Many functions of multi-user operating systems are invisible to the user.
4) Resource sharing: This maps to time slicing, multiple peripherals such as printers can
be shared different files or data.

 Advantages: -

1) It helps in the sharing of data and information among different users.


2) It also helps in the sharing of hardware resources such as printers.
3) It avoids disruption if any one computer fails it does not affect any other computer
present on that network.
4) Users can share their work with other users.
5) The multi-user operating system is very helpful in economic improvement.
6) Backing up data can be done in the multi-user operating system.

4
 Disadvantages: -
1) It requires expensive hardware to set up a mainframe computer.
2) When multiple users log on or work on the same system it reduces the overall
performance of the system.
3) Information is shared with the public so privacy becomes a concern here.

5
Practical No: -2
User administration in Windows and Linux operating system

The User Administration tool allows you to configure a wide range of ways for users to
access the system.

 User administration basics: -


The User Administration tool is accessed from the GUI by using the Tools tab.
 User management: -
User Management covers the tasks of adding and maintaining users and groups.
 User Administration Command Line Tool: -

The user admin tool provides a means of creating and deleting users as well as upgrading
user passwords.

 In windows: -
1) Select Start > Settings > Accounts and then select Family & other users. (In some
versions of Windows, you will see other users).
2) Next to Add other user, select Add account.
3) Select I do not have this person's sign-in information, and on the next page, select
Add a user without a Microsoft account.
4) Enter a user name, password, or password hint — or choose security questions —
and then select Next.

6
 In Linux: -
Linux User Administration denotes how to manage a user account or group accounts. It
deals with creating the user account, adding the user to the group, modifying it as well as
deleting the account.

 Types of users: -
There are three types of users in Linux: - root, regular and service.

 The root user account: -


This is the main user account in Linux system. It is automatically created during the
installation. It has the highest privilege in system.

 The regular user account: -


This is the normal user account. During the installation, one regular user account is
created automatically.

 The service account: -


Service accounts are created by installation packages when they are installed. These
accounts are used by services to run processes and execute functions.

 User creation: -
The first step in Linux user administration is knowing how to create user accounts. We
can use either user add or add user command followed by the username:

sudo add user [username] Or sudo user add [username]

Fig. 2.2(User creation)

7
 Account modification: -
To modify an already existing account, we use usermod command:

usermod -d /home/ [user_account_name]

Fig. 2.3(Account modification)

 How To View Available Users: -


Every user on a Linux system, whether created as an account for a real human being or
associated with a
particular service or system function, is stored in a file called /etc/passwd.

Have a look by using the less command, so you can scroll through the entire file:
$ less /etc/passwd.

8
Practical No: -3(a)
Write a program for the simulation of FCFS non-pre-emptive CPU scheduling algorithm to
find turnaround time and waiting time.

#include<iostream>
#include <iomanip>
using namespace std;
int main ()
{
int i, at [50] = {0}, bt [50] = {0}, sum=0, ct [50] = {0}, tat [50] = {0}, wt [50] = {0}, n;
cout<<"\nEnter the no. of processes= ";
cin>>n;
cout<<endl;
for (i = 0; i <n; i++)
{
cout<<"Enter the Arrival Time for process "<<i+1<<"=";
cin>>at[i];
}
cout<<endl;
for (i = 0; i <n; i++)
{
cout<<"Enter the Burst Time for process "<<i+1<<"=";
cin>>bt[i];
}
//Completion Time
for (int j = 0; j <n; j++)
{
sum=sum+bt[j];
ct[j]=ct[j]+sum;
}
//Turn Around Time

9
for (int k = 0; k <n; k++)
9
{
tat[k]=ct[k]-at[k];
}
//Waiting Time
for (i = 0; i <n; i++)
{
wt[i]=tat[i]-bt[i];
}
cout<<endl;
cout<<"PROCESSES ARRIVAL TIME BURST TIME COMPLITION TIME TURN
AROUND
TIME WAITING TIME";
cout<<endl;
for (int l=0; l<n; l++)
{
cout<<"PROCESS "<<l+1<<setw(8)
<<at[l]<<setw (15) <<bt[l]<<setw(15) <<ct[l]<<setw(17)<<tat[l]<<setw(17)<<wt[l]<<endl;
}
return 0;
}
Output: -

10

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy