Satellite API listActiveSystemsDetails returns XML entity error
Environment
- Red Hat Satellite 5.6
Issue
- When calling the listActiveSystemsDetails Satellite API call the following error is returned:
XML or text declaration not at start of entity at line 35, column 76
- DMI, CPU, RAM and/or Swap information is null and causes a Null Pointer Exception
- System(s) were registered with --nohardware flag
Resolution
- Current workaround is to schedule a hardware refresh through the Satellite GUI for the affected systems. Please contact GSS if you need to determine the exact set of systems that are affected.
- Bugzilla 1061484 has been created and a patch is in progress.
Root Cause
- The rhnServerDMI table does not have corresponding rows for the Server that is being iterated over from the listActiveSystemsDetails API call
Diagnostic Steps
- If using perl Frontier client you can set the debug flag when creating the client:
my $client = new Frontier::Client(url => "http://$HOST/rpc/api", debug=>1);
- The following debug output will be similar to the following:
XML or text declaration not at start of entity at line 35, column 76, byte 3983 at /usr/lib64/perl5/vendor_perl/XML/Parser.pm line 187
</value></data></array></value></member><member><name>dmi_info</name><value><?xml version="1.0" encoding="UTF-8"?><methodResponse><fault><value><struct><member><name>faultCode</name><value><int>-1</int></value></member><member><name>faultString</name><value><string>java.lang.NullPointerException: null</string></value></member></struct></value></fault></methodResponse>
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
