Courseiva
System SecurityhardMultiple ChoiceObjective-mapped

LPIC-2 System Security Practice Question

An AppArmor profile for a database server is too restrictive and denies legitimate queries. The administrator wants to learn the required accesses by running the application in complain mode. Which command puts the profile into complain mode?

⚠ Common exam trap

Watch out — candidates often confuse `aa-complain` with `aa-logprof` or `aa-disable`, as candidates may think disabling the profile is the safest way to learn accesses, but complain mode is specifically designed for this purpose without removing all security.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

aa-complain /etc/apparmor.d/usr.sbin.mysqld

The `aa-complain` command places an AppArmor profile into complain mode, where policy violations are logged but not blocked. This allows the administrator to run the database server and observe which accesses are denied, then use the logs to update the profile with the required permissions. The correct syntax is `aa-complain /etc/apparmor.d/usr.sbin.mysqld` to target the specific profile file.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • aa-complain /etc/apparmor.d/usr.sbin.mysqld

    Why this is correct

    Puts the profile in complain mode, logging violations without blocking.

  • aa-disable /etc/apparmor.d/usr.sbin.mysqld

    Why it's wrong here

    Disables profile entirely.

  • aa-enforce /etc/apparmor.d/usr.sbin.mysqld

    Why it's wrong here

    Enforces profile, blocking accesses.

  • aa-log /etc/apparmor.d/usr.sbin.mysqld

    Why it's wrong here

    No such command.

About these practice questions

Courseiva writes every LPIC-2 question from scratch — 507 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This LPIC-2 practice question is part of Courseiva's free LPI certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LPIC-2 exam.