CIS118 Intro to UNIX

CIS118 Intro to UNIX

CIS118 Intro to LINUX Name__________________________ Quiz #2 1. What’s the difference between using “>” and “>>” in redirection? What happens to a existing file if you use “>” to redirect to it? What happens to a existing file if you use “>>” to redirect to it? What happens if you “>>” to a file that doesn’t exist? 2. Write the command to create the directory CIS118 in your HOME directory, regardless of where the HOME directory is or where you are in the directory structure. (Hint: use the environment variable). 3. Write the command to allow only the owner to have read and write access to a file called “security.breaks” using the “numeric method”. 4. Write the command to send your home directory long listing to a file called “dir.list”; regardless of where you are in the LINUX directory. Write the command to send the first 10 items in a long list of the “root” directory to a file called short.dir. 5. Write the command to copy file /etc/profile from root to your HOME directory regardless of where your HOME directory is located. 6. Describe the difference between the commands “which “whereis” and “locate” as applied to the file called “whereis”. Show an example of each. What is the equivalent “find” command or this function for the file named “whereis” 7. Write the command to copy the file FILE2.txt to FILE2.old. Write the command to rename FILE2.old to FILE2. What happens? Why? Write the command to erase the file FILE2.old. 8. What is is the difference between files “file1” and “file2” when created by the commands “touch file1” and “echo ‘’ > file2” as indicated by the difference between a long listing of the two files. 9. In LINUX/UNIX everything is a ________________ or a _________________. 10. True/False: the command “mv ./dir1/file1 ./dir2” creates a new file on the hardrive. I know this because this command shows me ____________________. .

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    1 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us