0% found this document useful (0 votes)
92 views1 page

Linux Command Practice Guide

The document provides instructions for practicing common Linux commands by having the user create directories, files, modify permissions, search for files, compress files into a tarball, view system logs, check disk usage, and view and kill processes. The user is guided through 30 steps to get hands-on experience with fundamental Linux commands like mkdir, touch, cp, mv, chmod, chown, grep, cut, tar, man, journalctl, df, top, and kill.

Uploaded by

Betzy Iñiguez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
92 views1 page

Linux Command Practice Guide

The document provides instructions for practicing common Linux commands by having the user create directories, files, modify permissions, search for files, compress files into a tarball, view system logs, check disk usage, and view and kill processes. The user is guided through 30 steps to get hands-on experience with fundamental Linux commands like mkdir, touch, cp, mv, chmod, chown, grep, cut, tar, man, journalctl, df, top, and kill.

Uploaded by

Betzy Iñiguez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Implementation of operating systems

UD EXTRA: LINUX COMMNADS

PRACTICE LINUX COMMANDS:

1. Open a terminal.
2. Use the mkdir command to create a new directory called "UnixExercise."
3. Change to the newly created directory.
4. Create an empty file named "[Link]" using touch.
5. Use ls to list the contents of the directory and verify that "[Link]" has been created.
6. Copy "[Link]" to a new file named "[Link]" using cp.
7. Display the contents of "[Link]" using cat.
8. Open "[Link]" with the vi text editor and add a line of text. (Inside vi, press i to
enter insert mode, type your text, then press Esc followed by :wq to save and exit).
9. Search for the line you just added in "[Link]" using grep.
10. Use cut to extract the first word from "[Link]."
11. Rename "[Link]" to "[Link]" with mv.
12. List the contents of the directory again.
13. Create a new directory called "backup" with mkdir.
14. Copy "[Link]" to the "backup" directory using cp.
15. Change the permissions of "[Link]" with chmod so that only the owner can
write to it.
16. Change the owner of "[Link]" to another user using chown.
17. Use find to search for all files in the current directory.
18. Compress the current directory into a file named "[Link]" with tar.
19. Display the first 5 lines of the "[Link]" file with head.
20. Display the last 5 lines of the "[Link]" file with tail.
21. Sort the lines of the "[Link]" file alphabetically with sort.
22. Count the number of lines in "[Link]" with wc.
23. Create a new user named "new_user" with useradd.
24. Delete the newly created user with userdel.
25. Modify the properties of the current user with usermod.
26. Access the ls manual using man.
27. Check system logs with journalctl.
28. Display disk usage information with df.
29. View running processes with top or htop.
30. Finally, identify the process we just started (possibly the terminal) and stop it using
kill. Make sure to use the correct PID.

You might also like