Client Registration with Satellite fails with an error 'module' object has no attribute 'UTC'

Solution Verified - Updated -

Issue

  • Unable to register client using subscription-manager command due to error of AttributeError: 'module' object has no attribute 'UTC'

    Error: 
    
    File "/usr/lib/python2.7/site-packages/dateutil/parser/_parser.py", line 1374, in parse
    return DEFAULTPARSER.parse(timestr, **kwargs)
    File "/usr/lib/python2.7/site-packages/dateutil/parser/_parser.py", line 660, in parse
    ret = self._build_tzaware(ret, res, tzinfos)
    File "/usr/lib/python2.7/site-packages/dateutil/parser/_parser.py", line 1201, in _build_tzaware
    aware = naive.replace(tzinfo=tz.UTC)
    AttributeError: 'module' object has no attribute 'UTC'
    2022-04-26 13:28:06,382 [ERROR] subscription-manager:15544:MainThread @managercli.py:545 - 'module' object has no attribute 'UTC'
    

Environment

  • Red Hat Satellite 6
  • Red Hat Enterprise Linux 7

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

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content