Prompt "Invalid username or password" when using subscription-manager to register

Solution Verified - Updated -

Issue

  • When using the subscription-manager register command to register a system with --username and --password option, and the password contains a special character like $/^/#, it will return the Invalid username or password error.
# subscription-manager register --username=XXXXX --password=XXXX$XXXX
Registering to: subscription.rhsm.redhat.com:443/subscription
Invalid username or password. To create a login, please visit https://www.redhat.com/wapps/ugc/register.html
  • But, if we use the subscription-manager register command and enter the password manually, it's okay and the system could register to RHSM.
# subscription-manager register
Registering to: subscription.rhsm.redhat.com:443/subscription
Username: XXXXX
Password:
The system has been registered with ID: XXXXXXXXXX
  • And we can use the same username and password to login Red Hat Customer Portal.

Environment

  • 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