Linux Hands-on Part-2

Linux Hands-on Part-2

  1. To view what's written in a file.

  2. To change the access permissions of files

    1. Read (r) : The read permission allows you to open and read the content of a file. But you can't do any editing or modification in the file.

    2. Write (w) : The write permission allows you to edit, remove or rename a file. For instance, if a file is present in a directory, and write permission is set on the file but not on the directory, then you can edit the content of the file but can't remove, or rename it.

    3. Execute (x): In Unix type system, you can't run or execute a program unless execute permission is set. But in Windows, there is no such permission available.

hello.txt is a file which has rw- as a user permission, r-- as a group permission and r-- as an other permission. so hello.txt has 644 permission and file3.txt has 644 permission if we want to change the permission of both the file as user-rwx, group-rw-,other---- then execute below command

  1. check which commands you have run till now.

    To remove a directory/ Folder

    To create a fruits.txt file and to view the content

Add content in devops.txt (One in each line) - Apple, Mango, Banana, Cherry, Kiwi, Orange, Guava

To Show only top three fruits from the file

To Show only bottom three fruits from the file

To create another file Colors.txt and to view the content & Add content in Colors.txt - RED GREEN WHITE PURPLE ORANGE MANGO KIWI

Thanks for reading my blog, Hope you find this helpful !