Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please do all the parts and ill give you a thumbs up Part 3: Permissions for files Follow the instructions step by step and finish

image text in transcribed
image text in transcribed
please do all the parts and ill give you a thumbs up
Part 3: Permissions for files Follow the instructions step by step and finish the questions as required. 1) Go into your Lab3 directory. $ed - /Lab3 2) Check the file permissions for file "Try.c" in your own Lab3 directory. $1s -I Try.c 3) You may see similar output as below, in which rw-rw- -- of the first field is the file permission string for "Try.c". Trondelligid.grund snowball th35 18 ry.c -TW.1 frondellesund.go.edu frondelleuad.go.edu 379 Jan 21 11:57 1 The leftmost 3 characters rw- tells us that the user (owner of the file) can only read and write the file. The middle 3 characters rw-tells us the other users in the same group as the owner can only read and write the file. The last 3 characters r tells us the other users in the other groups different from owner can only read the file. Note: once you copy a file from other directory or download a file from other resources, you are the owner of the new copied or downloaded file. 4) Remove the read permission for the owner (yourself). Schmod u-F TEY.C 5) Check the file permissions for file "Try.c" again. $ 18 -1 Try.c 6) You may see similar output as below, in which -w-rw-r-- of the first field is the file permission string for "Try.c". Trondelauad, qu.edutanowball Labs 1 - Toys - 1 frondelleuad.gau.edu frondelligeudonu.edu373 Jan 2011138 TEY So -w- in the leftmost 3 characters tells us that the user (owner of the file) only has the permission to write something into the file, 7) Try the vi editor again to modify the file. Svi Try. 8) However, you may find following message displayed at the bottom of the screen which means you do not have the right to read "Try.c". "Ery.c (Permission Denied 9) Quit vi editor :9 10) Try read "Try.c" again using cat. Scat Try. Attach a screenshot of the output. 11) Use chmod with an octal number to let all the users only have read permission for "Try.c". Schmod 444 Try.c Note: The permission string to be set should be r-r---. Convert each group of three characters into decimal to form an octal number, which should be 444. 12) Check the file permissions for file "Try.c" again. And explain the meaning of each character in the file permission string. 13) Try the vi editor again to modify the file. Then remove one line by pressing dd Svi Try.c Move your cursor to some line and press dd 14) Try to save the file in the vi editor. 15) Can you find some error message at the bottom of the screen? If yes, what is it and how to quit the vi editor without saving the modification. Write answer in your answer sheet. 16) Use chmod to add write the permission to all the users for "Tiy.c". Write answer in your answer sheet. 17) Check the file permissions for file "Try.c" again. And explain the meaning of each character in the file permission string Write answer in your answer sheet

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Next Generation Databases NoSQLand Big Data

Authors: Guy Harrison

1st Edition

1484213300, 978-1484213308

More Books

Students also viewed these Databases questions