Which command would you use to check the SELinux status?

Disable ads (and more) with a premium pass for a one time $4.99 payment

Prepare for the Red Hat Certified Architect Exam with our comprehensive quiz. Master your skills with multiple choice questions and detailed explanations. Gear up to excel!

To check the SELinux status, using the 'sestatus' command is the most effective and straightforward method. When invoked, 'sestatus' provides detailed information about the current status of SELinux, including whether it is enabled or disabled, the current mode (enforcing, permissive, or disabled), and the SELinux policy being used.

This command is specifically designed to give comprehensive insights into SELinux's operational state, which is critical for system administrators who need to ensure their system is compliant with security policies.

Other commands serve different purposes: for example, 'getsebool -a' lists all the SELinux boolean values but does not indicate the overall status of SELinux itself. 'selinuxenabled' simply returns a success or failure status depending on whether SELinux is enabled but lacks detailed output. 'semanage status' is related to managing SELinux policies and does not specifically provide the SELinux status. This makes 'sestatus' the appropriate choice for checking SELinux status directly.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy