RHCE Cheat Sheet 2026

The 30 highest-yield RHCE facts, distilled from real exam questions. Print it, save it as a PDF, or study it here — free, no sign-up.

60 questions
90 min time limit
70.00% to pass
  1. What command builds a container image from a `Containerfile` in the current directory? podman build -t myimage .
  2. Which systemd command shows the output (logs) of a timer-triggered service? journalctl -u myservice.service
  3. What command syntax is used to perform a dry run (check mode) of an Ansible playbook without making changes? ansible-playbook -C playbook.yml
  4. Which command cleans all cached DNF package data, metadata, and headers from the local cache? dnf clean all
  5. How do you save the output from an Ansible module to a variable? register: var_name
  6. What is a Pod in the context of Podman? A group of containers sharing network and IPC namespaces
  7. What log file contains SELinux denial messages (AVC denials)? /var/log/audit/audit.log
  8. Which bash construct tests if a variable `$FILE` exists as a regular file? if [ -f $FILE ]
  9. What is the Samba directive that limits access to systems on the example.org network? hosts allow .example.org
  10. Which command loads a compiled SELinux policy module named `mypolicy.pp`? semodule -i mypolicy.pp
  11. What command syntax is used to perform a syntax check on an Ansible playbook? ansible-playbook --syntax-check playbook.yml
  12. Which command generates a systemd unit file to run a Podman container as a service? podman generate systemd mycontainer
  13. What is the relevant SELinux boolean associated with the sharing of home directories on Samba? samba_enable_home_dirs
  14. What DNF command lists all currently installed packages on the system? dnf list installed
  15. Which command locks a user account to prevent login? Both A and B
  16. Which command forces user `jdoe` to change their password on next login? passwd -e jdoe
  17. (SHELL) How do you tell if a file is of a certain type? test -f /var/cache/man/whatis
  18. What mount option in `/etc/fstab` causes a file system to be mounted read-only? ro
  19. What is the SELinux file type appropriate for shared Samba directories? samba_share_t
  20. What is the purpose of the `/etc/cron.deny` file? Lists users who are NOT allowed to use crontab
  21. Which option in `mkfs.xfs` sets a label for a new XFS file system? -L
  22. What command generates an SELinux policy module from audit denials to allow a previously blocked action? audit2allow -M mypolicy
  23. What keyword is used for looping over a list (which can be a variable) in Ansible? loop
  24. How do you check whether a downloaded RPM file's signature is valid before installing it? Both B and C are correct
  25. Which command removes the 'vsftpd' package along with any packages that depend on it? dnf remove vsftpd
  26. What field in `/etc/passwd` specifies the user's default shell? 7th field
  27. What does the `id` command display when run as a normal user? UID, GID, and group memberships
  28. What is the purpose of `skopeo` in a RHEL container workflow? Inspects and copies container images between registries without running them
  29. Which configurations in ansible.cfg are used for privilege escalation? become, become_method, become_user, become_ask_pass
  30. Which Ansible module is used for creating and editing filesystems? mount
Turn these facts into recall: