DEV Community

Cover image for Practical lab Questions On Linux(Day 6)
Kenneth Mahon
Kenneth Mahon

Posted on

Practical lab Questions On Linux(Day 6)

It has been an interesting 5 days of learning devOps and you guys have been so wonderful with the Encouragement; Thanks guys!!!
So i decided to test myself on all i have learnt so far by participating in a practical lab questions set by my Teammate and senior, motivator and mentor in Tech. He is also a member of this platform; His name is UWABOR COLLINS

i will be sharing the questions as well, so you all can also play with with them. Enjoy guys!!

    LAB QUESTIONS 
Enter fullscreen mode Exit fullscreen mode
  1. How do you check the current working directory?
  2. How do you create a new directory?
  3. How do you navigate to a directory?
  4. How do you list all files and directories in a directory?
  5. How do you display the contents of a file?
  6. How do you create a new file?
  7. How do you rename a file?
  8. How do you delete a file?
  9. How do you copy a file to a new location?
  10. How do you move a file to a new location?
  11. How do you create a symbolic link to a file?
  12. How do you search for a file by name or content?
  13. How do you change the owner of a file?
  14. How do you change the permissions of a file?
  15. How do you create a new user account?
  16. How do you change the password for a user account?
  17. How do you switch to a different user account?
  18. How do you log out of a user account?
  19. How do you view the system's IP address?
  20. How do you view the details of network interfaces?

PROJECT BASED QUESTIONS

  1. How would you use the ls command to display only the files in a directory (not directories)?
  2. Using the mkdir command, create a new directory called "my_folder" within your home directory.
  3. How would you move a file called "file1.txt" from your current directory to "my_folder"? Use the mv command. 4.How would you copy all files in a directory called "my_files" to a new directory called "backup_files"? Use the cp command.
  4. Using the rm command, delete a file called "old_file.txt" from your home directory.
  5. How would you create an empty file called "new_file.txt" in your current directory? Use the touch command.
  6. Using the echo command, write the message "Hello, world!" to a new file called "greeting.txt".
  7. How would you use the cat command to display the contents of a file called "notes.txt" on the terminal?
  8. How would you use the tail command to display the last 10 lines of a file called "log.txt"?

okay guys; that is all for day 6. You can share your answers with me. Day 7 loading

Top comments (2)

Collapse
 
devopsking profile image
UWABOR KING COLLINS

Thanks man small small we all go get there

Collapse
 
kennethstack profile image
Kenneth Mahon

sure
we will surely get there