Description of problem: Attempting to create a Host in Satellite 6.4 fails with the following error: "Invalid single-table inheritance type: Host::Discovered is not a subclass of Host::Managed" Version-Release number of selected component (if applicable): Red Hat Satellite 6.4 How reproducible: Steps to Reproduce: 1. Create a non-admin user - see "User_roles.txt" attachment 2. Use API to attempt host creation - See "api_call.txt" attachement Actual results: Logs and output return error: "Invalid single-table inheritance type: Host::Discovered is not a subclass of Host::Managed" (Also see "production.log.gz" attachment) Expected results: Host is created successfully. Additional info: This is not an issue when using "admin", but only a user with specific roles. However, these same users/roles were able to create the host in Satellite 6.3 successfully. (Thus setting "regression")
Per the support case, it turned out that the omitting the Step 4 of removing the pre-6.4 discovered hosts in https://access.redhat.com/documentation/en-us/red_hat_satellite/6.4/html/upgrading_and_updating_red_hat_satellite/upgrading_red_hat_satellite#upgrading_satellite_server_parent contributed to the conflict that was preventing non-admin users from creating the hosts. Once those Discovered Hosts were removed, the issue went away. This bugzilla can probably be closed
This is now recurring in the customer environment whenever there is a discovered host. This raises the severity as it is blocking provisioning
You don't need a custom role, you can use our pre-existing Org Admin role: With a discovered host in the queue: User with org-admin: 10.3969349861 seconds: create_host POST 500 https://example.com/api/v2/hosts u'{\n "error": {"message":"Invalid single-table inheritance type: Host::Discovered is not a subclass of Host::Managed"}\n}\n' User with full admin: 1.47844290733 seconds: create_host POST 201 https://example.com/api/v2/hosts
Created attachment 1499432 [details] Stack Trace
Uploaded the full error
Connecting redmine issue https://projects.theforeman.org/issues/25207 from this bug
Guys, looking into this. Upstream reported this as well and it was in my TODO anyway.
Hello, there's one liner available passing upstream tests: https://github.com/theforeman/foreman/pull/6192/files In case customer do not want to wait, please assist them with hotfixing their instance(s) until we do a final z-stream release.
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/25207 has been resolved.
Verified on Satellite 6.4 sn 1, having unprovisioned discovered host present in Satellite I was able to create a host via api using a user with org-admin role
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:3799