Here are the 50 practical scenarios to help you understand and use basic essential tools in Linux systems, which are important for the RHSA (Red Hat Certified System Administrator) exam:
File and Directory Operations:
1. Create a directory named “docs” in your home directory.
2. List the contents of a directory in long format.
3. Navigate to the parent directory using the “cd” command.
4. Create an empty text file named “notes.txt.”
5. Copy a file from one directory to another.
6. Move a file from one directory to another.
7. Rename a file using the “mv” command.
8. Remove a file using the “rm” command.
9. Create a symbolic link to a file.
10. Create a hard link to a file.
File Permissions and Ownership:
11. Change the permissions of a file to make it executable.
12. Change the owner and group of a file using the “chown” command.
13. Create a new user and assign them to a specific group.
14. Grant read and write permissions to a group for a specific file.
15. View the permissions of a file in octal notation.
16. Remove read and write permissions from a file for the owner.
Text Editing:
17. Open and edit the “notes.txt” file using the “vi” or “nano” text editor.
18. Search for a specific word within a text file using “grep.”
19. Display the first 10 lines of a text file using “head.”
20. Display the last 10 lines of a text file using “tail.”
21. Append text to an existing file using the “echo” command and the “>>” operator.
22. Create a copy of a text file with a different name.
Process Management:
23. Display a list of running processes using the “ps” command.
24. Terminate a specific process using the “kill” command.
25. Find and display information about a process using “pgrep” and “pmap.”
26. Start a background process using the “&” symbol.
27. Schedule a command to run at a specific time using “at” or “cron.”
User and Group Management:
28. Create a new user with a home directory and assign them to a primary group.
29. Add the new user to a secondary group.
30. Change the password for a user using the “passwd” command.
31. Display information about a specific user using the “id” command.
32. Remove a user account, including their home directory.
33. Create a new group and add users to it.
Networking and Connectivity:
34. Display the IP address and network configuration of your system using “ifconfig” or “ip.”
35. Test network connectivity to a remote server using the “ping” command.
36. View a list of open network ports on your system using “netstat” or “ss.”
37. Check the DNS configuration and resolve a domain name using “nslookup.”
Package Management:
38. Install a new package using the package manager (e.g., “yum” or “dnf”).
39. Update all installed packages to their latest versions.
40. Remove a package and its associated dependencies.
41. List installed packages containing a specific keyword.
42. Search for information about a package using “rpm” or “dnf info.”
Archiving and Compression:
43. Create a compressed archive of a directory using “tar.”
44. Extract the contents of a compressed archive.
45. List the contents of a compressed archive without extracting it.
46. Compress a file or directory using “gzip” or “bzip2.”
System Information and Monitoring:
47. Display system information, including kernel version and hardware details.
48. Monitor system resource usage using “top” or “htop.”
49. Check disk space usage on all mounted filesystems.
50. View the contents of system log files (e.g., “/var/log/messages”).
Note :
These scenarios cover essential tools and commands commonly used in Linux administration. Practicing these tasks on a Linux system will help you become more familiar with them, which is valuable for the RHSA exam and real-world system administration tasks.