> 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/solution/hosts-with-pf9-glance-role-failing-to-converge-with-error-incon.md).

# Hosts With pf9-glance Role Failing To Converge With Error "inconsistent use of tabs and spaces in indentation

## Problem

Hosts with ***pf9-glance*** role fail to converge. The following error is observed in the *glance-api.log*:

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

```none
ERROR stevedore.extension [-] Could not load 'cinder': inconsistent use of tabs and spaces in indentation (rbd.py, line 704): File "/opt/pf9/glance/lib/python3.6/site-packages/rbd.py", line 704
```

{% endtab %}
{% endtabs %}

## Environment

* Platform9 Managed OpenStack - v5.0 and below
* *Ceph*
* *Glance*

## Cause

Use of tabs and spaces for indentation in the *rbd.py* file.

## Resolution

1. Add the following environment variables on the *Glance* host.

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

```none
LD_LIBRARY_PATH="/opt/pf9/python/pf9-lib:$LD_LIBRARY_PATH"LD_LIBRARY_PATH="/opt/pf9/glance/lib:${LD_LIBRARY_PATH}"export LD_LIBRARY_PATHPYTHONPATH="/opt/pf9/python/lib/python3.6:${PYTHONPATH}"PYTHONPATH="/opt/pf9/glance/lib/python3.6/site-packages:${PYTHONPATH}"export PYTHONPATH
```

{% endtab %}
{% endtabs %}

2\. Install *autopep8* using *pip.*

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

```none
~$ /opt/pf9/glance/bin/python /opt/pf9/glance/bin/pip install autopep8==1.5.1
```

{% endtab %}
{% endtabs %}

3\. Correct the formatting issues by running the following command.

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

```none
~$ /opt/pf9/python/bin/python /opt/pf9/python/lib/python3.6/site-packages/autopep8.py -i /opt/pf9/glance/lib/python3.6/site-packages/rbd.py
```

{% endtab %}
{% endtabs %}

4\. Restart the ***pf9-glance-api*** service.

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

```none
~$ sudo service pf9-glance-api restart~$ service pf9-glance-api status
```

{% 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 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/solution/hosts-with-pf9-glance-role-failing-to-converge-with-error-incon.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.
