Satellite 6: How to extract client system information / facts without installing puppet agent package?
Environment
- Red Hat Satellite 6
Issue
- How to extract client system information without installing Satellite 6 puppet agent package?
- How to get Host system facts from Satellite 6 via API / commandline / CLI ?
Resolution
- The full set of facts gathered via subscription manager can be fetched via our REST API by passing the fields=full param to include all the facts:
Content from satellite.example.com is not included.http://satellite.example.com/katello/api/systems/<UUID?fields=full
eg:
curl -k -u admin:***** https://localhost/katello/api/systems/42bf6cd2-14c7-4c21-b29b-527fb6bd31d6?fields=full
{
"uuid": "42bf6cd2-14c7-4c21-b29b-527fb6bd31d6",
"name": "dhcp-8-30-202.lab.eng.rdu2.redhat.com",
...
"facts": {
"lscpu.vendor_id": "GenuineIntel",
"dmi.chassis.power_supply_state": "Safe",
"network.ipv4_address": "10.8.30.202",
"dmi.bios.rom_size": "64 KB",
"net.interface.lo.ipv6_netmask.host": "128",
"cpu.topology_source": "kernel /sys cpu sibling lists",
"net.interface.eth1.ipv4_broadcast": "10.8.31.255",
"dmi.chassis.thermal_state": "Safe",
"lscpu.l1i_cache": "32K",
"net.interface.eth1.ipv4_address": "10.8.30.202",
"distribution.version": "6.6",
"dmi.bios.runtime_size": "96 KB",
"dmi.bios.bios_revision": "1.0",
"dmi.memory.array_handle": "0x1000",
"dmi.system.version": "RHEL 6.5.0 PC",
"virt.is_guest": "true",
"dmi.memory.total_width": "64 bit",
"memory.swaptotal": "4063224",
"net.interface.lo.ipv6_address.host": "::1",
"dmi.system.product_name": "KVM",
"system.certificate_version": "3.2",
"net.interface.eth1.ipv4_netmask": "19",
"dmi.memory.size": "6000 MB",
"uname.version": "#1 SMP Sun Nov 10 22:19:54 EST 2013",
"dmi.bios.version": "0.5.1",
"dmi.chassis.version": "Not Specified",
"lscpu.cpu(s)": "1",
"lscpu.numa_node0_cpu(s)": "0",
"uname.nodename": "dhcp-8-30-202.lab.eng.rdu2.redhat.com",
"dmi.chassis.security_status": "Unknown",
"dmi.memory.speed": " (ns)",
"dmi.system.wake-up_type": "Power Switch",
"dmi.chassis.asset_tag": "Not Specified",
"memory.memtotal": "5845968",
"lscpu.on-line_cpu(s)_list": "0",
"dmi.memory.form_factor": "DIMM",
"dmi.processor.socket_designation": "CPU 1",
"lscpu.numa_node(s)": "1",
"lscpu.socket(s)": "1",
"dmi.system.status": "No errors detected",
"dmi.memory.data_width": "64 bit",
"net.interface.lo.ipv4_address": "127.0.0.1",
"lscpu.stepping": "3",
"lscpu.cpu_family": "6",
"dmi.memory.maximum_capacity": "6000 MB",
"net.interface.lo.ipv4_netmask": "8",
- From Satellite 6.2.x onward the API call changes as below:
# curl --request GET --insecure --user username:password https://satellite.example.com/api/hosts/:host_id/facts | json_reformat
Note: This requires no use of Puppet and is available to every host registered with subscription-manager.
For more KB articles/solutions related to Red Hat Satellite 6.x Puppet Issues, please refer to the Red Hat Satellite Consolidated Troubleshooting Article for Red Hat Satellite 6.x Puppet Issues
SBR
Product(s)
Category
Tags
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.