Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2218930 - hammer job-invocation create --feature katello_errata_install --inputs only installs 1 errata
Summary: hammer job-invocation create --feature katello_errata_install --inputs only i...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Hammer
Version: 6.13.1
Hardware: x86_64
OS: Linux
medium
high
Target Milestone: 6.14.0
Assignee: Oleh Fedorenko
QA Contact: Peter Ondrejka
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-06-30 15:40 UTC by Taft Sanders
Modified: 2023-11-08 14:20 UTC (History)
5 users (show)

Fixed In Version: rubygem-hammer_cli-3.7.0.1-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-08 14:19:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 36258 0 Normal Closed Installation of multiple errata failed because of reg-exp 2023-07-28 12:35:07 UTC
Red Hat Issue Tracker SAT-19236 0 None None None 2023-07-28 12:36:11 UTC
Red Hat Product Errata RHSA-2023:6818 0 None None None 2023-11-08 14:20:08 UTC

Description Taft Sanders 2023-06-30 15:40:06 UTC
Description of problem:
Unable to install more than 1 errata via command `hammer job-invocation create --inputs` using either key=value pairs or valid json

Version-Release number of selected component (if applicable):
satellite-6.13.1

How reproducible:
Every time

Steps to Reproduce:
1. Register a system to a Satellite with 2 or more errata that are installable
2. Try to install 2+ errata using the --inputs option
3.

Actual results:
Only installs 1 of the listed errata

Expected results:
Should install all errata that are installable

Additional info:
Workaround:
Adding the list of errata to a text file, comma separated, no spaces like:
RHBA-2023:0001,RHSA-2023:0002,RHEA-2023:0003
and referencing that file using the option '--input-file' in place of '--inputs' like the following:
--input-files "errata=/tmp/test.txt"

Full example:
# cat /tmp/test.txt 
RHBA-2023:1989,RHBA-2023:3486

# hammer job-invocation create --feature katello_errata_install --search-query "drone79.usersys.redhat.com" --input-files "errata=/tmp/test.txt"

//From the template rendering we can see that the yum command being passed to the client is as follows:
--------------    
    #!/bin/bash

# Helper function that exits with a particular message and code.
#
# Usage:
#   exit_with_message "Could not do a thing" 2
#
exit_with_message () {
  echo "${1}, exiting..."
  exit $2
}



# Action
  yum -y update-minimal --advisory="RHBA-2023:1989 --advisory=RHBA-2023:3486"
RETVAL=$?
[ $RETVAL -eq 0 ] || exit_with_message "Package action failed" $RETVAL
--------------

Comment 7 Oleh Fedorenko 2023-07-27 14:02:40 UTC
Connecting redmine issue https://projects.theforeman.org/issues/36258 from this bug

Comment 8 Bryan Kearney 2023-07-28 12:03:11 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36258 has been resolved.

Comment 16 Peter Ondrejka 2023-08-21 12:58:41 UTC
Verified on Sat 6.14 snap 12

Comment 19 errata-xmlrpc 2023-11-08 14:19:54 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 (Important: Satellite 6.14 security and bug fix update), 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-2023:6818


Note You need to log in before you can comment on or make changes to this bug.