After updating to RHEL 7.x, rpm and yum command fails with "Failed to initialize NSS library"

Solution Verified - Updated -


  • rpm and yum fail with "error: Failed to initialize NSS library"

    # rpm -qa
    error: Failed to initialize NSS library
    # rpm -Va
    error: Failed to initialize NSS library
    # yum update
    error: Failed to initialize NSS library
    There was a problem importing one of the Python modules
    required to run yum. The error leading to this problem was:
       cannot import name ts
    Please install a package which provides this module, or
    verify that the module is installed correctly.
    It's possible that the above module doesn't match the
    current version of Python, which is:
    2.7.5 (default, May  3 2017, 07:55:04) 
    [GCC 4.8.5 20150623 (Red Hat 4.8.5-14)]
    If you cannot solve this problem yourself, please go to 
    the yum faq at:


  • 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