Bug 1944708

Summary: Hammer host create fails with Error: usergroup not found
Product: Red Hat Satellite Reporter: tstrych
Component: HostsAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED ERRATA QA Contact: tstrych
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9.0CC: ehelms, inecas
Target Milestone: 6.10.0Keywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-11-16 14:10:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description tstrych 2021-03-30 14:09:30 UTC
Description of problem:
https://community.theforeman.org/t/hammer-host-create-fails-with-error-usergroup-not-found/20374
I reproduce issue described in https://projects.theforeman.org/issues/30814 
with satellite 6.9 snap 16


How reproducible:
Always

Steps to reproduce:
1. create host and user
2. update host owner
this don't work
hammer host update --id="61" --owner="QcSyNy"'
this work
hammer host update --id="60" --owner="MwOZeYtnRXAB" --owner-type="User"'

Actual results:
Unable to update a host without owner type.

Expected results:
Use some default one. User for example.

Additional info:
Not sure if this bug does not already exist.

Comment 1 Oleh Fedorenko 2021-03-30 17:31:18 UTC
Connecting redmine issue https://projects.theforeman.org/issues/30814 from this bug

Comment 2 Bryan Kearney 2021-04-13 10:17:24 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/30814 has been resolved.

Comment 3 tstrych 2021-06-15 15:07:24 UTC
Verified with sat 6.10 snap 4.

hammer host update --id 3 --owner='user1'
>>> Host updated.

the previous functionality works as well
hammer host update --id 4 --owner='user2' --owner-type="User"
>>> Host updated.

Comment 6 errata-xmlrpc 2021-11-16 14:10:29 UTC
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 (Moderate: Satellite 6.10 Release), 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/RHSA-2021:4702