Openstack overcoud scale out fails with: derive_pci_passthrough_whitelist.py ... ValueError: No JSON object could be decoded

Solution Unverified - Updated -

Issue

The Ansible failed task shows:

TASK [run derive_pci_passthrough_whitelist.py] *********************************
    fatal: [localhost]: FAILED! => {"changed": true, "cmd": ["/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py"], "delta": "0:00:00.571837", "end": "2023-04-06 10:11:41.118246", "msg": "non-zero return code", "rc": 1, "start": "2023-04-06 10:11:40.546409", "stderr": "Traceback (most recent call last):\n  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 308, in <module>\n    user_configs = user_passthrough_config()\n  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 149, in user_passthrough_config\n    return json.loads(out)\n  File \"/usr/lib64/python2.7/json/__init__.py\", line 338, in loads\n    return _default_decoder.decode(s)\n  File \"/usr/lib64/python2.7/json/decoder.py\", line 366, in decode\n    obj, end = self.raw_decode(s, idx=_w(s, 0).end())\n  File \"/usr/lib64/python2.7/json/decoder.py\", line 384, in raw_decode\n    raise ValueError(\"No JSON object could be decoded\")\nValueError: No JSON object could be decoded", "stderr_lines": ["Traceback (most recent call last):", "  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 308, in <module>", "    user_configs = user_passthrough_config()", "  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 149, in user_passthrough_config", "    return json.loads(out)", "  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"], "stdout": "", "stdout_lines": []}

If you prettify the json:

{
  "changed": true,
  "cmd": [
    "/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py"
  ],
  "delta": "0:00:00.571837",
  "end": "2023-04-06 10:11:41.118246",
  "msg": "non-zero return code",
  "rc": 1,
  "start": "2023-04-06 10:11:40.546409",
  "stderr": "Traceback (most recent call last):\n  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 308, in <module>\n    user_configs = user_passthrough_config()\n  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 149, in user_passthrough_config\n    return json.loads(out)\n  File \"/usr/lib64/python2.7/json/__init__.py\", line 338, in loads\n    return _default_decoder.decode(s)\n  File \"/usr/lib64/python2.7/json/decoder.py\", line 366, in decode\n    obj, end = self.raw_decode(s, idx=_w(s, 0).end())\n  File \"/usr/lib64/python2.7/json/decoder.py\", line 384, in raw_decode\n    raise ValueError(\"No JSON object could be decoded\")\nValueError: No JSON object could be decoded",
  "stderr_lines": [
    "Traceback (most recent call last):",
    "  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 308, in <module>",
    "    user_configs = user_passthrough_config()",
    "  File \"/var/lib/pci_passthrough_whitelist_scripts/derive_pci_passthrough_whitelist.py\", line 149, in user_passthrough_config",
    "    return json.loads(out)",
    "  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"
  ],
  "stdout": "",
  "stdout_lines": []
}

Environment

  • Red Hat OpenStack Platform 16

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