Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This is in Unix Problem 7 (12 points): Answer the following questions about the chmod command: a) Numeric notation uses digits to represent the permission
This is in Unix
Problem 7 (12 points): Answer the following questions about the chmod command: a) Numeric notation uses digits to represent the permission bits to be set, whereas symbolic notation usesto identify the user type and permissions. b) Using symbolic notation, how would you add read and write permission for the group? c) Using symbolic notation, how would you set the permission of the user to be read and write, but no execute? d) Using numeric notation, how would you assign the permission string -rwxr-X--x e Using numeric notation, how would you assign the permission string f In Linux, if you have a link to a file rather than the actual file, can you change the permissions of the link using chmod? (hint: look up the Linux man page for chmod)? g) Which Unix command allows you to change the owner of a file? MANAGING FILESDIRECTORIES Problem 8 (18 points): Answer the following questions regarding managing files and directories: a) What command would delete the directory lopt/uselessFiles including all of the files and subdirectories within it? b) What command flag can you use with cp so that it doesn't accidentally overwrite a file if it already exists (hint: look up the man page for cp)? c) Which command can be used to rename a file or directory? d) What command exists to delete a directory if and only if it is already empty? Give the needed commands to accomplish the following scenario (use only 1 command for each one, and assume that each command affects the commands that follow it): e) Change to the directory /opt/games/ f Create a new directory called "pacman" inside of this directory 8) While still inside of /opt/games, create a new file called "highscores" inside of the pacman directory (use a relative path/file name instead of an absolute path/file name) h) While still inside of /opt/games, rename the "highscores" file inside of the pacman directory to "scores" use an for both source and destination filenames) instead of a relative path/file name i) Change to the directory "pacman" j) Set the permissions of the "scores" file (using numeric notation) to be -rw-r--r k) Make a copy of the "scores" file in this same directory called "scores.backup ) Change to the parent directory /opt/games/ using .. notation m) Inside of this directory, remove the empty directory "tetris (assume it exists) n) Delete all of the files inside of the "pacman" directory, including the "pacman directory itselfStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started