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

Essential Linux Commands Explained

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)
7 views11 pages

Essential Linux Commands Explained

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

Aman Kumar 25711

OS Assignment

Question -2: Execute various LINUX Commands for:

i. Information Maintenance : wc, clear, cal, who, date, pwd

wc – Counts Number of Lines, Words and Bytes in a given file.

clear – Clears the Command Terminal.


cal – Displays a Calendar in Terminal.

who – Displays Information about users currently logged into the


system.
date – Displays Date and Time of the System.

pwd – pwd Stands for Present Working Directory. Displays the


Current Directory.

ii. File Management : cat, cp, rm, mv, cmp, comm, diff, find, grep,
awk

cat – Displays the Content of File.


cp – Copies File to given Directory.
rm – Remove Files/Directories from the System.
mv – Renames/ Moves the File.
cmp – Compares Two Files Byte by Byte It’s primary purpose is to
determine if two files are identical or to locate first difference
between them.
comm – It compares two files line by line and identifies line that
are unique to each file and those that are common to both.

diff – It compares two files line by line and display the differences
between them.
find – Used to find for a specific file/directory.

grep – grep stands for Global Regular Expression Prints. It


searches for given expression in files(s).
awk – It processes text line by line, allowing you to perform actions based
on patterns or conditions found within each line.

iii. Directory Management : cd, mkdir, rmdir, ls

cd – Changes Directory.

mkdir – Creates a New Directory with the name given.

rmdir – Removes Directory with the Name specified.

ls – Displays Directories or Files present in pwd.

You might also like