Hybrid Quiz 2 (Material from w03-w04) 3

pdf

School

Algonquin College *

*We aren’t endorsed by this school

Course

CST8102

Subject

Computer Science

Date

Feb 20, 2024

Type

pdf

Pages

4

Uploaded by ProfessorStrawMouse21

Report
Important: Written answers commands are automatically graded. Enter them accurately according to the following: 1. Use -5 instead of —n 5 with the relevant commands 2. Use only the minimum and absolutely required options 3. Write options before the other arguments (1f the command permits) For example: 1ls -1 1l.txt instead of 1ls 1l.txt -1 4. Use exactly one space to separate arguments, options, pipes, and redirections. For example: echo hello | wc instead of: echo hello|wc 5. Use fgrep instead of grep 6. Remove redundant spaces 1n the beginning and end Question 1 (1 point) Saved Which command can copy one directory to another? O copytree (:)dup Q cpdir Question 2 (1 point) Saved Enter the complete command to have all newly created files with execute permission for owner, group and others. If it 1s not possible, answer none [ umask 666 ] Ay
Question 3 (1 point) Saved If foo 1s an empty sub-directory, what happens after this command line: date >foo/single ; mv foo/single double C:)the command fails because single is not a directory <:)a new empty file named double is created there 1s a second copy of the file single 1n the file named double (:)the directory foo is now empty (:)the command fails because the name double does not exist Question 4 (1 point) Saved Enter the complete command to set all newly created files and directorilies to have no permissions for the user, group and others. Use 3 digits octal permissions mode. [ umask 777 ] Ay Question 5 (1 point) Saved What 1s this symbolic mode i1in octal (Enter 3 octal digits) —IWXYX—XX—— E g Question 6 (1 point) Saved Which of the following commands displays the information in the inode?
Question 7 (1 point) Saved You are 1in an unknown directory. Copy the file 1l.txt from your home directory to the sub-directory sub which i1s directly under your home directory. Use the shortest pathname (s) possible. Use the minimal number of required options. 4 ) cp ~/1.txt ~/sub Question 8 (1 point) Saved What 1s the minimum permission needed on a directory to do:mv 1.txt 2. txt Question 9 (1 point) Saved Copy the file 1.txt 1n the parent directory i1nto the current directory, and name 1t copy.txt
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
4 ) cp ../1.txt copy.txt Question 10 (1 point) Saved What i1is the minimum permission needed on the file 1l.txt to: 1n 1.txt 2.txt m 10 of 10 questions saved