RHCSA RHCSA EX200 3 — Questions and Answers
Question 1: A cron job must run as user 'deploy' every weekday at 7:30 AM. Which crontab entry is correct?
- 30 7 * * 1-5 deploy /script.sh (Correct answer)
- 30 7 * * Mon-Fri /script.sh
- 7 30 * * 1-5 /script.sh
- * 7:30 * * 1-5 /script.sh
Correct answer: 30 7 * * 1-5 deploy /script.sh
Crontab fields are minute hour dom month dow; '30 7 * * 1-5' means 7:30 AM Monday through Friday.
Question 2: Which NFS mount option ensures that if the NFS server is unreachable, the mount operation does not hang the system indefinitely?
- hard
- soft (Correct answer)
- bg
- intr
Correct answer: soft
The 'soft' option causes NFS operations to return an error after a timeout instead of retrying indefinitely.
Question 3: You want to find all SUID files on the system. Which find command is correct?
- find / -perm -4000 -type f (Correct answer)
- find / -perm 4000 -type f
- find / -mode SUID
- find / -special suid
Correct answer: find / -perm -4000 -type f
The '-perm -4000' with the leading dash means the SUID bit must be set, regardless of other permission bits.
Question 4: Which file controls the sudo privileges for users and groups on a RHEL system, and should be edited with 'visudo'?
- /etc/sudoers (Correct answer)
- /etc/sudo.conf
- /etc/security/sudoers
- /etc/pam.d/sudo
Correct answer: /etc/sudoers
/etc/sudoers defines who can run what commands as which users; visudo validates syntax before saving.
Question 5: To mount an XFS filesystem at /data persistently, which /etc/fstab entry is correct?
- /dev/sdb1 /data xfs defaults 0 0 (Correct answer)
- /dev/sdb1 /data ext4 defaults 0 0
- UUID=xxx /data xfs defaults 0 1
- /dev/sdb1 /data xfs auto 1 1
Correct answer: /dev/sdb1 /data xfs defaults 0 0
For a non-root XFS partition, the last two fields should be 0 0 (no dump, no fsck) since xfs_repair is used manually.
Question 6: Which command shows the current SELinux mode and displays whether it is enforcing, permissive, or disabled?
- sestatus (Correct answer)
- seinfo
- semanage status
- getsebool -a
Correct answer: sestatus
'sestatus' displays the current and configured SELinux mode along with the policy type.
Question 7: How do you list all currently active firewalld zones and their associated interfaces?
- firewall-cmd --list-all-zones
- firewall-cmd --get-active-zones (Correct answer)
- firewall-cmd --info zones
- firewall-cmd --show-zones
Correct answer: firewall-cmd --get-active-zones
'--get-active-zones' shows only zones that have interfaces or sources assigned, along with those assignments.
A cron job must run as user 'deploy' every weekday at 7:30 AM.
Which crontab entry is correct?