Managed OpenStack
Latest
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:
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
Environment
Platform9 Managed OpenStack - v5.0 and below
Ceph
Glance
Cause
Use of tabs and spaces for indentation in the rbd.py file.
Resolution
Add the following environment variables on the Glance host.
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
2. Install autopep8 using pip.
~$ /opt/pf9/glance/bin/python /opt/pf9/glance/bin/pip install autopep8==1.5.1
3. Correct the formatting issues by running the following command.
~$ /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
4. Restart the pf9-glance-api service.
~$ sudo service pf9-glance-api restart~$ service pf9-glance-api status
Last updated on
Was this page helpful?
Frequently Asked Questions
Solution
How To
Internal Only
Templates
Powered by
