0% found this document useful (0 votes)
24 views1 page

Linux_Commands_Explanation

The document provides explanations for basic Linux commands including ls, rmdir, cat, mkdir, pwd, cd, chgrp, and chmod. Each command is accompanied by a brief description and an example of its usage. These commands are essential for file and directory management in a Linux environment.

Uploaded by

Sonit Marwah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views1 page

Linux_Commands_Explanation

The document provides explanations for basic Linux commands including ls, rmdir, cat, mkdir, pwd, cd, chgrp, and chmod. Each command is accompanied by a brief description and an example of its usage. These commands are essential for file and directory management in a Linux environment.

Uploaded by

Sonit Marwah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

Linux Command Explanations

ls
Lists all files and directories in the current directory.

Example: ls -l (lists all contents in long format including permissions, size, and modification
date)

rmdir
Removes an empty directory.

Example: rmdir example_directory (removes a directory named example_directory if it is


empty)

cat
Concatenates and displays the content of files.

Example: cat file.txt (displays the content of file.txt)

mkdir
Creates a new directory.

Example: mkdir new_directory (creates a new directory called new_directory)

pwd
Prints the current working directory.

Example: pwd (displays the path of the current directory)

cd
Changes the directory.

Example: cd /home/user (changes the current directory to /home/user)

chgrp
Changes the group ownership of a file or directory.

Example: chgrp group_name file.txt (changes the group ownership of file.txt to group_name)

chmod
Changes the permissions of a file or directory.

Example: chmod 755 file.txt (sets the permissions of file.txt to read, write, and execute for
the owner, and read and execute for group and others)

You might also like