cloud-init.service failed with 'ImportError: cannot import name UnrewindableBodyError' after yum update

Solution Verified - Updated -

Issue

  • Initial cloud-init job failed to start after yum update
# systemctl status cloud-init
● cloud-init.service - Initial cloud-init job (metadata service crawler)
   Loaded: loaded (/usr/lib/systemd/system/cloud-init.service; enabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Thu 2020-11-19 16:53:41 KST; 1min 4s ago
  Process: 70155 ExecStart=/usr/bin/cloud-init init (code=exited, status=1/FAILURE)
 Main PID: 70155 (code=exited, status=1/FAILURE)

Nov 19 16:53:41 localhost cloud-init[70155]: File "/usr/lib/python2.7/site-packages/urllib3/connection.py", line 45, in <module>
Nov 19 16:53:41 localhost cloud-init[70155]: from .util.ssl_ import (
Nov 19 16:53:41 localhost cloud-init[70155]: File "/usr/lib/python2.7/site-packages/urllib3/util/__init__.py", line 5, in <module>
Nov 19 16:53:41 localhost cloud-init[70155]: from .request import make_headers
Nov 19 16:53:41 localhost cloud-init[70155]: File "/usr/lib/python2.7/site-packages/urllib3/util/request.py", line 5, in <module>
Nov 19 16:53:41 localhost cloud-init[70155]: from ..exceptions import UnrewindableBodyError
Nov 19 16:53:41 localhost cloud-init[70155]: ImportError: cannot import name UnrewindableBodyError
Nov 19 16:53:41 localhost systemd[1]: Failed to start Initial cloud-init job (metadata service crawler).
Nov 19 16:53:41 localhost systemd[1]: Unit cloud-init.service entered failed state.
Nov 19 16:53:41 localhost systemd[1]: cloud-init.service failed.

Environment

  • Red Hat Enterprise Linux 7
  • cloud-init

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In