Which command permanently enables an SELinux boolean to allow httpd to read user content?

Prepare for the Red Hat Certified Systems Admin Exam EX200. Enhance your skills with interactive quizzes, flashcards, and detailed explanations. Ace your certification exam today!

Multiple Choice

Which command permanently enables an SELinux boolean to allow httpd to read user content?

Explanation:
SELinux booleans control permissive capabilities for services, and some of them must be turned on or off to allow actions like httpd reading user content. The important part here is making that change permanent so it sticks after a reboot. Using setsebool with the -P option stores the chosen state in the policy, ensuring the setting survives reboots. Providing the value 1 explicitly enables the boolean, so the HTTP daemon will be allowed to read user content even after restart. Without -P, the change only applies at runtime and is lost on reboot. Using true as the value is not as universally supported as 1, and while some versions may accept it, the portable, reliable form is 1 with -P. Using on could work on some systems, but the clearly persistent and unambiguous choice here is -P with 1.

SELinux booleans control permissive capabilities for services, and some of them must be turned on or off to allow actions like httpd reading user content. The important part here is making that change permanent so it sticks after a reboot. Using setsebool with the -P option stores the chosen state in the policy, ensuring the setting survives reboots. Providing the value 1 explicitly enables the boolean, so the HTTP daemon will be allowed to read user content even after restart.

Without -P, the change only applies at runtime and is lost on reboot. Using true as the value is not as universally supported as 1, and while some versions may accept it, the portable, reliable form is 1 with -P. Using on could work on some systems, but the clearly persistent and unambiguous choice here is -P with 1.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy