10 RHCSA EX200 Practice Questions That Mirror the Real Exam
Here are 10 multiple-choice questions designed to match the difficulty and style of the RHCSA EX200 exam, covering key domains such as file management, user administration, permissions, and system services.
RHCSA EX200 Practice Questions
These questions test your practical knowledge of Red Hat Enterprise Linux system administration, focusing on the objectives outlined in the official exam guide. Read each question carefully and choose the best answer.
Question 1
A user reports that they cannot log in to a system. You need to temporarily disable their account without deleting their home directory or files. Which command should you use?
A. userdel -r username
B. passwd -l username
C. usermod --expiredate 1 username
D. usermod -s /sbin/nologin username
Answer: B
Explanation: The passwd -l command locks the user's password, preventing them from logging in with their password while preserving their account and data. userdel -r deletes the user and their home directory. usermod --expiredate 1 sets the account to expire immediately, but it's a more complex method. usermod -s /sbin/nologin changes the shell, which prevents interactive logins but might still allow other services like FTP or SCP depending on configuration, whereas locking the password is the standard, immediate method for disabling an account.
Question 2
You are asked to create a new group named finance with a specific GID of 1500. Which command accomplishes this?
A. groupadd -g 1500 finance
B. groupadd -r 1500 finance
C. newgrp -g 1500 finance
D. groupmod -g 1500 finance
Answer: A
Explanation: The groupadd command is used to create new groups. The -g option allows you to specify the GID. groupmod modifies an existing group, newgrp is used to switch your current group, and -r for groupadd creates a system group (with a GID from a different range).
Question 3
A user needs to find all files larger than 10MB in their home directory. Which single command would you recommend they use?
A. grep -r -size +10M /home/user
B. find /home/user -type f -size +10M
C. locate -size +10M /home/user
D. ls -lR -size +10M /home/user
Answer: B
Explanation: The find command is the standard tool for searching for files based on criteria like size, type, and name. The syntax find /home/user -type f -size +10M correctly searches for regular files (-type f) larger than 10 megabytes (-size +10M). grep searches within file contents, locate uses a database and doesn't filter by size directly, and ls doesn't have a size filter option.
Question 4
You have edited a configuration file for the httpd service. Which command will apply the changes without a full system reboot?
A. systemctl reload httpd
B. systemctl restart httpd
C. systemctl daemon-reload httpd
D. systemctl reset-failed httpd
Answer: A
Explanation: systemctl reload sends a signal to the service to reload its configuration files, which is the least disruptive method for applying changes. systemctl restart stops and starts the service, causing a brief downtime. daemon-reload is used to re-read systemd unit files, not application configs. reset-failed clears the "failed" state of a unit.
Question 5
A file has the permissions -rwxr-x---. Which of the following statements is true about this file?
A. The owner can read, write, and execute; the group can read and execute; others can read.
B. The owner can read, write, and execute; the group can read and execute; others have no access.
C. The owner can read and write; the group can read and write; others can execute.
D. The owner can read and execute; the group can read; others have no access.
Answer: B
Explanation: The permissions are broken down as: rwx (owner) r-x (group) --- (others). This means the owner has full read, write, and execute permissions. The group has read and execute permissions (no write). Others (everyone else) have no permissions at all.
Question 6
Which of the following commands will set the default permissions for newly created files to umask 027 for all users system-wide?
A. Add umask 027 to /etc/profile.
B. Run umask 027 in the current shell.
C. Edit the /etc/login.defs file and set UMASK 027.
D. Add umask 027 to the user's ~/.bashrc file.
Answer: A
Explanation: To set a default umask for all users system-wide, you must place the umask command in a global shell configuration file like /etc/profile or /etc/bashrc. Running it in the current shell only affects that session. Editing /etc/login.defs sets the default umask for new users, but it's only applied at user creation time, not for existing users. The user's ~/.bashrc only applies to that specific user.
Question 7
To schedule a one-time maintenance script /root/cleanup.sh to run at 3:00 AM next Tuesday, which tool is the most appropriate?
A. crontab -e
B. at 3:00 AM tuesday
C. systemd-run --on-calendar="Tue 03:00"
D. sleep 300000 && /root/cleanup.sh
Answer: B
Explanation: The at command is specifically designed for scheduling one-time jobs at a specified time. crontab is for recurring jobs. systemd-run with a calendar timer can do it, but it's more complex for a one-off task. Using sleep is a poor and unreliable method that ties up a terminal session.
Question 8
You are troubleshooting a network issue. You need to see the current routing table and the default gateway. Which command provides this information?
A. ss -r
B. ip route show
C. netstat -a
D. dig -r
Answer: B
Explanation: The ip route show command (or ip r) is the modern, standard tool to display the kernel's routing table, including the default gateway. ss -r is not a valid combination; ss is for socket statistics. netstat -a shows all sockets and connections, not specifically the routing table (you'd need netstat -r). dig is for DNS lookups.
Question 9
A user wants to copy a directory docs and all its contents from a local machine to a remote server server1 into the /home/user/backup directory. Which command is correct?
A. cp -r docs user@server1:/home/user/backup
B. scp -r docs user@server1:/home/user/backup
C. rsync -r docs user@server1:/home/user/backup
D. sftp docs user@server1:/home/user/backup
Answer: B
Explanation: scp (secure copy) is designed to copy files and directories over SSH. The -r option is required to copy directories recursively. cp only works locally. rsync is a powerful tool for this, but it's often used for synchronization and has different default behaviors; scp is the standard, straightforward answer. sftp is an interactive session, not a single command to copy a directory.
Question 10
You need to change the SELinux context of a file to httpd_sys_content_t so it can be served by Apache. Which command should you use?
A. chmod httpd_sys_content_t /var/www/html/index.html
B. chown httpd_sys_content_t /var/www/html/index.html
C. setsebool httpd_sys_content_t /var/www/html/index.html
D. chcon -t httpd_sys_content_t /var/www/html/index.html
Answer: D
Explanation: The chcon command is used to change the SELinux security context of a file. The -t option specifies the type, which in this case is httpd_sys_content_t. chmod changes file permissions, chown changes ownership, and setsebool modifies SELinux booleans (which are on/off switches, not file labels).
These questions represent a sample of the skills and knowledge required for the RHCSA EX200 exam. Remember to practice these tasks in a real RHEL environment to solidify your understanding. Focus on understanding the why behind each command, not just the command itself.
To prepare for these tasks on a schedule that fits your time, follow the free RHCSA study plan.
Stop guessing whether you are prepared — Red Hat Certified System Administrator (RHCSA) sample questions tell you objectively.
For a quick check of weak topics, you can take the free RHCSA readiness check.
