"No JSON object could be decoded" or JSONDecodeError when registering a system to Satellite6

Solution Verified - Updated -

Issue

  • Registering a RHEL8 system to Satellite6 fails with json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0).
Traceback (most recent call last):
  File "/usr/sbin/subscription-manager", line 11, in <module>
    load_entry_point('subscription-manager==1.23.8', 'console_scripts', 'subscription-manager')()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/scripts/subscription_manager.py", line 85, in main
    return managercli.ManagerCLI().main()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/managercli.py", line 2918, in main
    ret = CLI.main(self)
  File "/usr/lib64/python3.6/site-packages/subscription_manager/cli.py", line 183, in main
    return cmd.main()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/managercli.py", line 506, in main
    return_code = self._do_command()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/managercli.py", line 1400, in _do_command
    self.entcertlib.update()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/certlib.py", line 32, in update
    self.report = self.locker.run(self._do_update)
  File "/usr/lib64/python3.6/site-packages/subscription_manager/certlib.py", line 18, in run
    return action()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/entcertlib.py", line 42, in _do_update
    return action.perform()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/entcertlib.py", line 141, in perform
    self.content_access_hook()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/entcertlib.py", line 194, in content_access_hook
    update_data = self.content_access_cache.check_for_update()
  File "/usr/lib64/python3.6/site-packages/subscription_manager/cache.py", line 685, in check_for_update
    data = json.loads(self.read())
  File "/usr/lib64/python3.6/json/__init__.py", line 354, in loads
    return _default_decoder.decode(s)
  File "/usr/lib64/python3.6/json/decoder.py", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib64/python3.6/json/decoder.py", line 357, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
  • Registering a RHEL7 system to Satellite6 fails with No JSON object could be decoded.
# subscription-manager register --org Example --activationkey production-rhel7
The system has been registered with ID: d7aa87e7-c340-458e-aa48-dfb54b8c0632
The registered system name is: server01.example.com
Traceback (most recent call last):
  File "/sbin/subscription-manager", line 9, in <module>
    load_entry_point('subscription-manager==1.24.13', 'console_scripts', 'subscription-manager')()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/scripts/subscription_manager.py", line 85, in main
    return managercli.ManagerCLI().main()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/managercli.py", line 2922, in main
    ret = CLI.main(self)
  File "/usr/lib64/python2.7/site-packages/subscription_manager/cli.py", line 183, in main
    return cmd.main()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/managercli.py", line 506, in main
    return_code = self._do_command()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/managercli.py", line 1400, in _do_command
    self.entcertlib.update()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/certlib.py", line 32, in update
    self.report = self.locker.run(self._do_update)
  File "/usr/lib64/python2.7/site-packages/subscription_manager/certlib.py", line 18, in run
    return action()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/entcertlib.py", line 42, in _do_update
    return action.perform()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/entcertlib.py", line 141, in perform
    self.content_access_hook()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/entcertlib.py", line 194, in content_access_hook
    update_data = self.content_access_cache.check_for_update()
  File "/usr/lib64/python2.7/site-packages/subscription_manager/cache.py", line 684, in check_for_update
    data = json.loads(self.read())
  File "/usr/lib64/python2.7/json/__init__.py", line 338, in loads
    return _default_decoder.decode(s)
  File "/usr/lib64/python2.7/json/decoder.py", line 366, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib64/python2.7/json/decoder.py", line 384, in raw_decode
    raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded

Environment

  • Red Hat Enterprise Linux 8
  • Red Hat Enterprise Linux 7
  • Satellite 6.7
  • Satellite 6.6

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