> For the complete documentation index, see [llms.txt](https://platform9.com/kb/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://platform9.com/kb/pmo/how-to/vm-fails-to-boot-with-unable-to-find-security-driver-for-label.md).

# VM Fails to Boot With: 'Unable to find security driver for label apparmor'

## Problem

A virtual machine (VM) is unable to boot up with the following fault message.

{% tabs %}
{% tab title="None" %}

```none
{u'message': u'unsupported configuration: Unable to find security driver for label apparmor', u'code': 500}
```

{% endtab %}
{% endtabs %}

## Environment

* Platform9 Managed OpenStack - v3.6.0 and higher
* AppArmor
* Ubuntu 14.04

## Cause

The VMs' libvirtd process is a part of the AppArmor security module.

## Resolution

1. Remove the VM's libvirtd process from apparmor by running the command.

{% tabs %}
{% tab title="None" %}

```none
apparmor_parser -R /etc/apparmor.d/libvirt/libvirt-[__vm-uuid__]
```

{% endtab %}
{% endtabs %}

2. Open the XML definition of the VM for editing.

{% tabs %}
{% tab title="None" %}

```none
$ virsh edit [vm_uuid]
```

{% endtab %}
{% endtabs %}

3. Scroll to the end of the file until you see this line.

{% tabs %}
{% tab title="None" %}

```none
[seclabel type='dynamic' model='apparmor' relabel='yes'/]
```

{% endtab %}
{% endtabs %}

Change it to the following.

{% tabs %}
{% tab title="None" %}

```none
[seclabel type='none'/]
```

{% endtab %}
{% endtabs %}

4. If the VM was in a ShutOff state initially, start the VM from a virsh perspective.

{% tabs %}
{% tab title="None" %}

```none
virsh start [__vm_uuid__]
```

{% endtab %}
{% endtabs %}

5. If you are editing the XML of an already running instance you will have to stop and start VMs for the changes to take effect.

{% tabs %}
{% tab title="None" %}

```none
$ openstack server stop$ openstack server start
```

{% endtab %}
{% endtabs %}

## Additional Information

Please see the official [AppArmor Documentation](https://gitlab.com/apparmor/apparmor) for more details on working with this Mandatory Access Control (MAC) mechanism.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://platform9.com/kb/pmo/how-to/vm-fails-to-boot-with-unable-to-find-security-driver-for-label.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
