satellite-installer or subscription-manager commands fails with error 'cannot import name 'which'

Solution Verified - Updated -

Issue

  • satellite-installer command produces the following error.
2023-05-20 08:39:49 [ERROR ] [configure] cannot import name 'which'
2023-05-20 08:39:50 [ERROR ] [configure] cannot import name 'which'
2023-05-20 08:39:55 [ERROR ] [configure] cannot import name 'which'
  • subscription-manager commands fails with following error.
Unable to find Subscription Manager module.
Error: cannot import name 'which'

Environment

  • Red Hat Satellite 6
  • Red Hat Enterprise Linux Server

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