Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Class notes

Practicals of Operating systems

Rating
-
Sold
-
Pages
34
Uploaded on
30-12-2022
Written in
2021/2022

In these notes, Covered all the topics of operating systems briefly. COs - Analyze the structure of OS and basic architectural components involved in OS design. Compare and contrast various CPU scheduling algorithms. Evaluate the requirements for the process synchronization and co-ordination in the contemporary operating system. Analyze various algorithms for memory management, I/O management and security aspects of operating system. Write shell scripts in Unix/Linux O.S and write simple programs using kernel system calls. Also understand virtualization concept

Show more Read less
Institution
Course

Content preview

200090107080

Practical 1

Aim: Study of Basic commands of Linux/UNIX.

Solution:

Test directory command

pwd : Print working Directory
pwd stands for ‘present working directory’. When you write pwd on prompt it will display the
current working directory.
Usage: Print working Directory name.
Syntax: pwd
Example:




mkdir : make directory
This command is used to create a new directory.
Syntax : mkdir directory name.
Usage : Creates new directory.
Example:




cd : Change Directory
This command is used to change the directory.
Usage : Change working directory.
Syntax : cd [directory]
Options:
_cd …Change working directory to home directory
_ cd ..…change working directory to parent directory
_ cd /user/lib…change working directory to absolute path/user/lib _ cd doc/letters…change
working directory to relative path doc/letters

Example:




Operating System 1

, 200090107080

rmdir : Remove Directory

Remove Directory. This command is used to remove a directory.
Usage : Creates new directory
Syntax : rmdir directory name
Example :




File commands :


cat:
It is used to create a new file. Press ctrl + C to indicate EOF.
Cat > file name - Creates new file.
Cat >> filename - Appends data to an existing file.
Usage: Display file contents, creates new file , or appends data to an existing file.
Syntax: Cat < file name - Displays file contents.
Example:




ls:
It lists all the filenames in alphabetical order which are present in the current directory.
Usage : List out contents of a directory.
Syntax: ls [directory]
Example:


Operating System 2

, 200090107080




cp :
Copy command, this command is used to copy a file.
Usage : Copies a file or group of files.
Options:
i: interactive copying (Asks before overwriting a destination file.)
r: recursive copying (It copies directory structure)
Syntax : cp [-irp ] file1 [file2… ] target
Example:




mv :
Move / Rename file, this command is used to rename files.
Usage : Renames a file, or moves a file or group of files.
Syntax : mv [-if] file [file2 …] target
Example :




rm :
Removes file , this command removes the given file or files supplied to it.
Usage : Removes files (deletes files)
Syntax : rm [-f] [-i] [-r] file
Options :
-i: interactive removal
-r: Recursive removal
-f: Forceful removal
Example:




Operating System 3

, 200090107080

wc:
It contains the number of lines, words and characters from the specified file or files.
Usage:
counts the number of characters , words or lines in a given input file. If the file is not given it
takes input from standard input.
Syntax: wc[file]
Options:
-l counts number of lines
-w counts number of words
-c counts number of characters
Example:




chmod:
chmod command is used to change the access mode of the file.
Usage:
change file permissionsIn Relative mode , the options first indicate whose access is to be
changed u (user,you), g (group), o(other), or a (all) ; then indicate the type of action +
(add),- (delete), or = (set); and then specify the access to be set r(read) and w(write/delete)
or x (execute).In absolute mode , three numbers represent the protections for the user ,
group and others ,Each number is a sum of 1 (for execute access), 2(for write/delete access)
and 4 (for read access).
Syntax: chmod [ugoa] [rwx] file (Relative Permission)
Example:




cmp :
compare the cmp utilities compares two files of any type and writes the result to the standard
o/p.
Syntax : cmp file1 file2
Usage : compares two files and given the location of the first mismatch.
Example :




Operating System 4

Written for

Institution
Course

Document information

Uploaded on
December 30, 2022
Number of pages
34
Written in
2021/2022
Type
Class notes
Professor(s)
Ymk sir
Contains
All classes

Subjects

$3.99
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller
Seller avatar
vaibhav51ppsv2020

Also available in package deal

Get to know the seller

Seller avatar
vaibhav51ppsv2020 C.K.Pithawala school of engineering and techonology
Follow You need to be logged in order to follow users or courses
Sold
-
Member since
3 year
Number of followers
0
Documents
14
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions