Unable to register HTTP error (401 - Unauthorized): authorized

Latest response

I'm unable to register new machine RH 8.1.
I can connect to redhat.com via browser, but when I try to register the system I get HTTP error:

[root@m64 ~]# subscription-manager  register 
Registering to: subscription.rhsm.redhat.com:443/subscription
Username: name@company.cz
HTTP error (401 - Unauthorized): authorized

This is rhsm.log:

tail /var/log/rhsm/rhsm.log
    return self.conn.request_get(method)
  File "/usr/lib64/python3.6/site-packages/rhsm/connection.py", line 726, in request_get
    return self._request("GET", method, headers=headers)
  File "/usr/lib64/python3.6/site-packages/rhsm/connection.py", line 752, in _request
    info=info, headers=headers)
  File "/usr/lib64/python3.6/site-packages/rhsm/connection.py", line 627, in _request
    self.validateResponse(result, request_type, handler)
  File "/usr/lib64/python3.6/site-packages/rhsm/connection.py", line 689, in validateResponse
    raise RestlibException(response['status'], error_msg, response.get('headers'))
rhsm.connection.RestlibException: HTTP error (401 - Unauthorized): authorized

Thank you for your help.


Getting the same error on RH 7.4, can anyone explain this?

enter your username not your email address .. we get this error while registering because we are using the full email address but it is asking for the username

correct. It works using without email id

I get the the same error like Petr on my x86_64 VM. It looks like something wrong on Red Hat Side. :( I will wait until Monday and check it again. Hope than it works

Same error/log entry here with RHEL 8.1 x86_64 also on a VM. Tried rebuilding and even tried different host/ISP. Guess like Dirk said, maybe have to wait until Monday...

We are observing the same problem, RHEL8.1

I also have the same proble. RHEL8.1

Problem got solved by: "Register the system using Red Hat Login ID as the username instead of using email address:" https://access.redhat.com/solutions/4173071

Sorry, not solved for me. I have got another error message only:

HTTP error (401 - Unauthorized): Ungültige Benutzer-Anmeldeinformationen

Username does now work for me either, but there is one more workaround: create an activation key and use it instead of username/password like this:

    subscription-manager register --org=<org-id> --activationkey=<activation-key-name>


EDIT: the subscription-manager orgs part of the above solution will not work in this case. I had to login to Customer portal and retrieve org ID and activation key ID from there.

Apparently there is a server side problem which breaks --user ... --password authentication for all subscription-manager commands.

Hello, this solved for me ! many thanks !

Thank-you Egor, that worked when nothing else would. I was trying to register a new RHEL Hyper-V client on my work desktop to my RH Developer subscription. Definitely used username in the past. But after creating an Activation Key in my RH Developer account was able to register.

Awesome. This method worked for me, Thank you so much.

Thank you so much. I was pulling my hair out. This is very helpful.

This tip solved my trouble too. Very thanks.

-- In 'thoughts'...

Thanks, it worked for me

As you have said, it has worked for me thanks a lot!

This worked for me. I could not use my account email address. Go to the Customer Portal, open your profile, your Username is the field you are looking for. Then register using Username/Password... Worked perfectly added the system/installed product in the subscription. Thank you.

Worked for me! Thx

Worked for me too with Username from Customer Portal/Profile. Initially I typed Red Hat Account Number but it is not this one, it is the Username under Profile. Thank you all!

Aye. Did spent 20 hours to know to use my account name "cgkeenan" instead of email address as used to log in the developers.redhat.portal. Use accound name instead email address.

Worked for me! Thanks bro

Thank you. Using my login ID instead of my email worked.

Thanks Xiaoguang, this works for me.

right !!!!

This one solved for me, RHEL 7.8. (subscription-manager register --username "my username only and not email" --password "my password") Thanks.

Solved here! thanks!

It worked for me, thanks mate!

To those who aren't sure of the correct username, open the system you created on RH Custome Portal, then under "Details > Registration history" use the content of "Created by" as your user on "subscription-manager register"

Thanks Xiaoguang!

Solved, for me at least

Sorry, this is no solution for me.

subscription-manager orgs --user= --password=

I will get the response: "authorized"

not real org_id

Petr, I had to create activation key on Redhat customer portal, I also got org ID from there.

If command-line authentication with --user ... --password is broken, it won't work for any of the subscription-manager commands ;) That looks like a server-side problem to me.

Thanks for finding that - I updated my reply.

For me solution with using activation token instead of user/password has helped. https://access.redhat.com/solutions/3341191 https://access.redhat.com/articles/1378093

subscription-manager register --username= enterusername NOT your email --password=****** --auto-attach this one works for me when i enter my username but, doesn't work if you enter email address. :) Thanks all

Thank you, now it works perfectly :-)

If you previously gave email as username. And now trying correctly with Red Hat Login ID as the username instead of using email address but not working for you. Then try clearing the cache first -

subscription-manager clean subscription-manager register subscription-manager attach --auto


Also, make sure your passwd doesn't have any special symbols or spaces. If so, change it first and then try again. https://access.redhat.com/solutions/4308451

I used the "-" character in my password and that was the issue. Changing my password fixed it.

OK! Solved.

Than you


Also try to avoid !-sign in passwords, these are considered escape to command line characters.


Jan Gerrit Kootstra

I just had this very same problem. The mistake everyone is making is using your email address when you are trying to register. Use your Username instead and not your email

HTTP error (401 - Unauthorized): authorized same error, tried all methods suggested in this thread but no success.

Hi Dear Friends, I am not able to register my redhat 8.1 system. can you help me for the error what can i do this error solve. this error is showing me As] = HTTP error (401 - Unauthorized): Service not available, please try again later.

Same here - RHEL 7.7 Registering to: subscription.rhsm.redhat.com:443/subscription HTTP error (401 - Unauthorized): Service not available, please try again later

Same here. RHEL 7.8 getting 401 error

I've has this happen multiple times over the last few days trying to setup a few virtual servers with RHEL 7.8. I found that I needed to login to Red Hat and change my password.. to the same password and things worked again. The issue was never my password in the first place, but resetting it back made the subscription manager work again. Frustrating.


Please open a support case if you get this issue.

Even a self-support subscription allows you to report registration issues


Jan Gerrit Kootstra

Anyone landing here, please start by reading Jan Gerrit Kootstra's post above mine, and please take the time to read through this entire long post for various things that worked for others. Keep in mind this discussion was created in November of 2019, and things over time may change.


Logging on to the Customer Portal and clicking 'Change Password' shows the "Red Hat Logon" for your account. This can then be used with the subscription manager command.

I read all the posts mentioned earlier. No luck. However: Changing one's password and using that new password worked immediately for me too.

Thanks for sharing Matthew!

any one