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

Operating System DA1

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Operating System DA1

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Name : Sankalp Singh Solanki

Reg no : 23MIS0002

OPERATING SYSTEMS Digital Assignment-1

List of Programs
1. Basic Linux commands (Execute 15 utility commands
on UNIX/Linux command prompt and print the outcome)
1)DATE

Print System date (date can be changed by system administrator) Options:- d (day of a month), y(2 digits of an
year), H,M,S (hour,minutes and seconds

2)MKDIR

Creates a new directory named operatingsystem . No output if successful.


3)RMDIR

Removes an empty directory named OS. No output if successful.

4)TIME
To calculate the time taken by a command time sort –o 1.c 2.c
time shows real(elapsed time),user(execution time), sys time(time by os to do the operation)

5)CLEAR

This command clears the screen.

6)TTY

Know the terminal name. Unix treats terminals in multiuser as files in device directory.
tty
7) Saving and Exiting From Vi:
Esc: wq Save all changes and quit
8)CAT
The 'cat' command is actually a concatenator but can be used to view the contents of a file.

9)wc command
Word count

This command counts lines, words and letters of the input given to it.

10)pwd command
‘pwd’ command prints the absolute path to current working directory.
11)Changing Directories Command
$ cd [path-to-directory]

Change the current working directory to the directory provided as argument. If no argument is given to ‘cd’, it changes the
directory to the user's home directory. The directory path can be an absolute path or relative to current directory. The absolute
path always starts with /. The current directory can be checked with ‘pwd’ command.
12)stat command

To check the status of a file. This provides more detailed information about a file.

13) touch

Create a New File

14) ls

List files to verify creation

15) echo

Use echo to add content to the file.


2. Shell Programming

a. Find the smallest of three numbers


b.Swapping of two numbers without using third variable
c. Check the grade of the students based on marks using elif

You might also like