Hide Forgot
Description of problem: Could not check the product status from SAM server side with API. Version-Release number of selected component (if applicable): katello-candlepin-cert-key-pair-1.0-1.noarch katello-certs-tools-1.4.2-2.el6sat.noarch katello-cli-1.4.3-8.el6sat.noarch katello-cli-common-1.4.3-8.el6sat.noarch katello-common-1.4.3-9.el6sam_splice.noarch katello-configure-1.4.4-3.el6sat.noarch katello-glue-candlepin-1.4.3-9.el6sam_splice.noarch katello-glue-elasticsearch-1.4.3-9.el6sam_splice.noarch katello-headpin-1.4.3-9.el6sam_splice.noarch katello-headpin-all-1.4.3-9.el6sam_splice.noarch katello-selinux-1.4.4-2.el6sat.noarch signo-katello-0.0.20-1.el6sat.noarch candlepin-0.8.21-1.el6sam.noarch candlepin-scl-1-5.el6_4.noarch candlepin-scl-quartz-2.1.5-5.el6_4.noarch candlepin-scl-rhino-1.7R3-1.el6_4.noarch candlepin-scl-runtime-1-5.el6_4.noarch candlepin-selinux-0.8.21-1.el6sam.noarch candlepin-tomcat6-0.8.21-1.el6sam.noarch thumbslug-0.0.32-1.el6sam.noarch thumbslug-selinux-0.0.32-1.el6sam.noarch subscription-manager: 1.8.21-1.el5 python-rhsm: 1.8.17-1.el5 How reproducible: always Steps to Reproduce: 1. Register to SAM and auto-attach [root@dhcp-65-69 ~]# cat /etc/rhsm/rhsm.conf hostname = samserv.redhat.com baseurl= https://samserv.redhat.com:8088 [root@dhcp-65-69 ~]# subscription-manager register --auto-attach Username: admin Password: The system has been registered with ID: 3be3671d-46f0-4e63-83fb-cb8d3248f3b7 Installed Product Current Status: Product Name: Red Hat Enterprise Linux Server Status: Subscribed 2. Check the product status from SAM server side with API (1) [root@dhcp-65-69 ~]# curl -k -u admin:admin --request GET https://samserv.redhat.com:443/subscription/consumers/3be3671d-46f0-4e63-83fb-cb8d3248f3b7/compliance | python -m simplejson/tool | grep status % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 163 0 163 0 0 2161 0 --:--:-- --:--:-- --:--:-- 8150 (2) [root@dhcp-65-69 ~]# curl -k -u admin:admin --request GET https://samserv.redhat.com:443/subscription/consumers/3be3671d-46f0-4e63-83fb-cb8d3248f3b7/compliance {"displayMessage":"User admin is not allowed to access api/v1/candlepin_proxies/get","errors":["User admin is not allowed to access api/v1/candlepin_proxies/get"]} (3) [root@dhcp-65-69 ~]# curl -k -u admin:admin --request GET https://samserv.redhat.com:443/subscription/consumers/3be3671d-46f0-4e63-83fb-cb8d3248f3b7 {"content_view_id":1,"created_at":"2013-08-30T04:43:43Z","description":"Initial Registration Params","environment_id":1,"id":119,"location":"None","name":"dhcp-65-69.nay.redhat.com","updated_at":"2013-08-30T04:43:43Z","uuid":"3be3671d-46f0-4e63-83fb-cb8d3248f3b7","href":"/consumers/3be3671d-46f0-4e63-83fb-cb8d3248f3b7","facts":{"virt.uuid":"8f03881b-855c-d768-c97d-402e7f75a7d6","dmi.chassis.power_supply_state":"Safe","dmi.memory.error_correction_type":"Multi-bit ECC","dmi.processor.upgrade":"Other","network.ipv4_address":"10.66.65.69","dmi.bios.rom_size":"64 KB","dmi.processor.family":"Other","cpu.topology_source":"kernel /sys cpu sibling lists","dmi.chassis.thermal_state":"Safe","cpu.thread(s)_per_core":"1","dmi.system.sku_number":"Not Specified","dmi.bios.runtime_size":"96 KB","distribution.version":"5.10","dmi.bios.bios_revision":"1.0","dmi.memory.array_handle":"0x1000","dmi.system.version":"RHEL 6.4.0 PC","virt.is_guest":"true","memory.swaptotal":"2097144","dmi.memory.total_width":"64 bit","dmi.system.product_name":"KVM","system.certificate_version":"3.2","net.interface.eth0.ipv4_address":"10.66.65.69","dmi.bios.vendor":"Seabios","distribution.id":"Tikanga","dmi.memory.location":"Other","dmi.memory.size":"1024 MB","dmi.chassis.type":"Other","uname.version":"#1 SMP Mon Aug 19 23:32:47 EDT 2013","dmi.bios.version":"0.5.1","cpu.core(s)_per_socket":"1","cpu.cpu(s)":"1","dmi.chassis.serial_number":"Not Specified","dmi.chassis.version":"Not Specified","virt.host_type":"kvm","uname.nodename":"dhcp-65-69.nay.redhat.com","dmi.memory.error_information_handle":"Not Provided","dmi.system.serial_number":"Not Specified","dmi.system.manufacturer":"Red Hat","net.interface.eth0.mac_address":"52:54:00:90:BD:75","cpu.cpu_socket(s)":"1","dmi.chassis.security_status":"Unknown","dmi.memory.speed":" (ns)","dmi.system.wake-up_type":"Power Switch","dmi.chassis.asset_tag":"Not Specified","memory.memtotal":"1034700","dmi.bios.relase_date":"01/01/2007","dmi.chassis.boot-up_state":"Safe","dmi.memory.form_factor":"DIMM","dmi.processor.socket_designation":"CPU 1","dmi.memory.use":"System Memory","dmi.processor.version":"Not Specified","dmi.memory.bank_locator":"Not Specified","dmi.system.status":"No errors detected","dmi.memory.data_width":"64 bit","net.interface.eth0.ipv4_netmask":"23","net.interface.lo.ipv4_broadcast":"Unknown","dmi.system.family":"Red Hat Enterprise Linux","dmi.processor.voltage":" ","net.interface.lo.ipv4_address":"127.0.0.1","distribution.name":"Red Hat Enterprise Linux Server","dmi.memory.maximum_capacity":"1 GB","net.interface.lo.ipv4_netmask":"8","uname.sysname":"Linux","dmi.processor.type":"Central Processor","dmi.memory.type":"RAM","uname.release":"2.6.18-370.el5","network.hostname":"dhcp-65-69.nay.redhat.com","dmi.processor.status":"Populated:Enabled","network.ipv6_address":"::1","uname.machine":"i686","dmi.chassis.manufacturer":"Red Hat","dmi.memory.locator":"DIMM 0","dmi.bios.address":"0xe8000","net.interface.eth0.ipv4_broadcast":"10.66.65.255","dmi.system.uuid":"8f03881b-855c-d768-c97d-402e7f75a7d6","dmi.chassis.lock":"Not Present"},"idCert":{"created":"2013-08-30T04:43:43.066+0000","updated":"2013-08-30T04:43:43.066+0000","key":"-----BEGIN RSA PRIVATE KEY-----\nMIIEogIBAAKCAQEAgzzCOti2bXPvdGUJu/MFECflPilqr4BaaxsboFIrpC3t0eAR\nVPMID+gOZHQZL+30PtbHqyaRvKzVL9PtINWgd0vdHnhP7EAHZEkqY8QE439QBFtA\n2LgYXBuL5DS0j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qz43YHfstcG1edOT/RUqTQvhisR/JGoF58vcEopxdGW5YD/19sD+UqYN\nh02dX2oR6YkhuRykmn48BP1eXEWeYTJFaqHhE4T8ebDOsQe9/pCc21/wR1XBaIn6\nki3Pm/2/0QIDAQABo4IBPjCCATowEQYJYIZIAYb4QgEBBAQDAgWgMAsGA1UdDwQE\nAwIEsDCBsAYDVR0jBIGoMIGlgBQBfwyR3Latct6MUpQ+oVTypdALJ6GBgaR/MH0x\nCzAJBgNVBAYTAlVTMRcwFQYDVQQIEw5Ob3J0aCBDYXJvbGluYTEQMA4GA1UEBxMH\nUmFsZWlnaDEQMA4GA1UEChMHU29tZU9yZzEUMBIGA1UECxMLU29tZU9yZ1VuaXQx\nGzAZBgNVBAMTEnNhbXNlcnYucmVkaGF0LmNvbYIJAIQgvj/ra4JfMB0GA1UdDgQW\nBBQh3eOis0atP4bnpEcDG7zrTb7q+jATBgNVHSUEDDAKBggrBgEFBQcDAjAxBgNV\nHREEKjAopCYwJDEiMCAGA1UEAwwZZGhjcC02NS02OS5uYXkucmVkaGF0LmNvbTAN\nBgkqhkiG9w0BAQUFAAOCAQEAjIWudjq3ThsQIr4hqBv2/f9zhpAgkYuDvlytJyq/\ndqgmKoWS1aq8Gy59twnPkJBGendb+i/a1U5rLcMjOwYM5RvDwX2fKmrpvYnVBFDe\nOxPeDpa7ybjuYocvyuoeddEQ65hNSEpfXo1DTskmzbhQwiGT/aUmxJsIQR91Bpza\nCSwZyayV4dApUi/JhW92K0P/9zjwN2CyZLMuIqfLGTVxjulzYcTtkeEVj/D1uS4k\nDaRy5R6uNi35F3kU9c22ZGXPzRyCMYV3y5CBFKgcbGLbwPQRkhB3lbTC72cT/8vY\n4DdtqeQqhvHnJ8nmbsCq3X7hPQECM3t5FPyGECwZckSBmQ==\n-----END CERTIFICATE-----\n","id":"8ac28dc740b8b3d40140cd88b45a0c29","serial":{"created":"2013-08-30T04:43:42.742+0000","updated":"2013-08-30T04:43:42.742+0000","id":5791645836176083985,"revoked":false,"collected":false,"expiration":"2029-08-30T04:43:42.741+0000","serial":5791645836176083985}},"owner":{"id":"8ac28dc740b8a0350140b8a160e00001","key":"ACME_Corporation","displayName":"ACME_Corporation","href":"/owners/ACME_Corporation"},"autoheal":true,"release":null,"releaseVer":{"releaseVer":null},"checkin_time":"2013-08-30T00:45:36-04:00","installedProducts":[{"productId":"69","productName":"Red Hat Enterprise Linux Server","version":"5.10","arch":"i386","status":"green","startDate":"2013-06-04T04:00:00.000+0000","endDate":"2014-06-04T03:59:59.000+0000"}],"capabilities":[],"serviceLevel":"","environment":{"id":1,"name":"Library","description":null,"library":true,"organization_id":1,"created_at":"2013-08-26T03:18:39Z","updated_at":"2013-08-26T03:18:39Z","label":"Library","prior":null,"prior_id":null,"organization":"ACME_Corporation"},"activation_key":[],"content_view":{"id":1,"name":"Default Organization View","label":"Default_Organization_View","description":null,"content_view_definition_id":null,"organization_id":1,"default":true,"created_at":"2013-08-26T03:18:39Z","updated_at":"2013-08-26T03:18:39Z","organization":"ACME_Corporation","definition":null,"environments":["Library"],"versions":[1],"versions_details":[{"version":1,"published":"2013-08-26 03:18:39","environments":["Library"]}]},"ipv4_address":"10.66.65.69","guests":[]}[root@dhcp-65-69 ~]# Actual results: As above. Expected results: Product status should be "status": "valid" when check it with curl ' curl -k -u admin:admin --request GET https://samserv.redhat.com:443/subscription/consumers/3be3671d-46f0-4e63-83fb-cb8d3248f3b7/compliance | python -m simplejson/tool | grep status' Additional info: I check the product status on stage candlepin, and the product status can be checked successfully. the katello-debug output is attached as 'katello-debug'
please try https://samserv.redhat.com:8088/sam/api/consumers/{id}/compliance. The url you are using appears to be hosted.
(In reply to Bryan Kearney from comment #2) > please try > https://samserv.redhat.com:8088/sam/api/consumers/{id}/compliance. The url > you are using appears to be hosted. Hi, Bryan I tried https://samserv.redhat.com:8088/sam/api/consumers/{id}/compliance according to your advice, but failed: [root@dhcp-65-69 ~]# curl -k -u admin:admin --request GET https://samserv.redhat.com:8088/sam/api/consumers curl: (35) error:14094412:SSL routines:SSL3_READ_BYTES:sslv3 alert bad certificate So, I tried to replace the port 8088 with 443: [root@dhcp-65-69 ~]# curl -k -u admin:admin --request GET https://samserv.redhat.com:443/sam/api/consumers {"displayMessage":"You have not set a default organization and environment on the user admin.","errors":["You have not set a default organization and environment on the user admin.",""]}
Hey, is there any updates for this bug? I am still not sure how to get/delete info from SAM/Satellite server with APIs.
The release of Satellite 5.8 we are deprecating the support of Subscription Asset Manager. The release notes for 5.8 can be found at https://access.redhat.com/documentation/en-us/red_hat_satellite/5.8/pdf/release_notes/Red_Hat_Satellite-5.8-Release_Notes-en-US.pdf. I am therefore closing out this bug as WONTFIX. If you believe this to be an error, please feel free tor each out to either Rich Jerrido or Bryan Kearney. Thank you!