← All RHCE Flashcard Decks

SELinux Administration Flashcards

6 cards from real RHCE practice questions. Tap to flip, then mark Knew It or Still Learning — missed cards come back until you master them.

Read the first 6 SELinux Administration flashcards as text
  1. Which command sets a permanent SELinux file context so it survives `restorecon`?

    Answer: semanage fcontext -a -t httpd_sys_content_t '/mydir(/.*)?'

    `semanage fcontext -a` adds a persistent file context rule to the SELinux policy database.

  2. What command enables the SELinux boolean `httpd_can_network_connect` persistently?

    Answer: setsebool -P httpd_can_network_connect on

    `setsebool -P` sets the SELinux boolean persistently, surviving reboots by writing to the policy.

  3. Which command lists all SELinux booleans and their current state?

    Answer: Both A and B

    Both `semanage boolean -l` and `getsebool -a` list all SELinux booleans with their current and default states.

  4. What log file contains SELinux denial messages (AVC denials)?

    Answer: /var/log/audit/audit.log

    SELinux AVC (Access Vector Cache) denial messages are written to `/var/log/audit/audit.log` by the auditd daemon.

  5. Which command analyzes SELinux denials and suggests fixes using audit2why?

    Answer: ausearch -m avc | audit2why

    `ausearch -m avc` extracts AVC denial messages which are then piped to `audit2why` for human-readable explanations.

  6. What does the `z` option do when used with `cp` (e.g., `cp -Z`)?

    Answer: Sets the context to default policy

    `cp -Z` sets the SELinux context of copied files to the default policy context for the destination.

How this page was made: written with AI tools and published by Nathan Beja, founder of Practice Test Geeks, who is responsible for its content. Exam facts are checked against the official sources listed below. Not reviewed by a subject-matter expert. Editorial policy

Sources & references

Exam facts on this page (fees, format, dates, passing scores) are checked against these official sources; the date is our last check. Editorial policy

  1. redhat.com — Test delivery, renewal, score validity, exam format, score release, exam information · verified Oct 2026