> 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/unable-to-obtain-pidfile-error-while-starting-libvirtd-service.md).

# "Unable to obtain pidfile" Error While Starting Libvirtd Service

## Problem

* ***libvirtd*** service failed to start with below error reported in */var/log/messages.*

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

```none
kdt-dpckvm01 libvirtd[404581]: libvirt version: 1.3.1, package: 1ubuntu10.24 (Marc Deslauriers [marc.deslauriers@ubuntu.com] Wed, 23 May 2018 13:29:29 -0400)kdt-dpckvm01 libvirtd[404581]: hostname: kdt-dpckvm01kdt-dpckvm01 libvirtd[404578]: /usr/sbin/libvirtd: error: Unable to obtain pidfile. Check /var/log/messages or run without --daemon for more info.kdt-dpckvm01 libvirtd[404581]: Failed to acquire pid file '/var/run/libvirtd.pid': Resource temporarily unavailablekdt-dpckvm01 systemd[1]: libvirt-bin.service: Main process exited, code=exited, status=1/FAILUREkdt-dpckvm01 systemd[1]: libvirt-bin.service: Unit entered failed state.kdt-dpckvm01 systemd[1]: libvirt-bin.service: Failed with result 'exit-code'.kdt-dpckvm01 systemd[1]: libvirt-bin.service: Service hold-off time over, scheduling restart.
```

{% endtab %}
{% endtabs %}

## Environment

* Platform9 Managed OpenStack - v3.6.0 and Higher

## Cause

The ***libvirtd*** service fails to start as the */var/run/libvirtd.pid* file is not accessible.

## Resolution

1. Remove PID file on the affected KVM host.

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

```none
$ rm -rf /var/run/libvirtd.pid
```

{% endtab %}
{% endtabs %}

2. Restart the ***libvirtd*** service on the KVM host.

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

```none
$ systemctl restart libvirt
```

{% endtab %}
{% endtabs %}


---

# 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 dynamically 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/unable-to-obtain-pidfile-error-while-starting-libvirtd-service.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 `build a script that syncs our docs to a CMS` 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.
