Bug 1759588 - "foreman-maintain packages update" fails to update all packages
Summary: "foreman-maintain packages update" fails to update all packages
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Satellite Maintain
Version: 6.6.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: 6.7.0
Assignee: Martin Bacovsky
QA Contact: Lukas Pramuk
URL:
Whiteboard:
Depends On:
Blocks: 1762651
TreeView+ depends on / blocked
 
Reported: 2019-10-08 14:54 UTC by Lukas Pramuk
Modified: 2020-04-14 12:58 UTC (History)
10 users (show)

Fixed In Version: rubygem-foreman_maintain-0.5.2
Doc Type: Known Issue
Doc Text:
The `foreman-maintain packages update all` command does not work. To update all packages on the Satellite base operating system, enter the `foreman-maintain packages update \\*` command.
Clone Of:
Environment:
Last Closed: 2020-04-14 12:58:36 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 28097 0 High Closed "foreman-maintain packages update" fails to update all packages 2020-10-19 12:51:15 UTC
Red Hat Product Errata RHBA-2020:1442 0 None None None 2020-04-14 12:58:48 UTC

Description Lukas Pramuk 2019-10-08 14:54:01 UTC
Description of problem:
"foreman-maintain packages update" fails to update all packages with:

ERROR: parameter 'PACKAGES ...': no value provided

It should work similar way as "yum update" works. No parameter means all packages. 

Yet worse, there is explicit all packages for yum as "\*"
But for foreman-maintain it needs to be escaped twice "\\*"

Not obvious nor documented.


Version-Release number of selected component (if applicable):
@Satellite 6.6.0 Snap22
rubygem-foreman_maintain-0.4.9-1.el7sat.noarch


How reproducible:
deterministic

Steps to Reproduce:
1. # foreman-maintain packages update
ERROR: parameter 'PACKAGES ...': no value provided

See: 'foreman-maintain packages update --help'

Actual results:
"foreman-maintain packages update" dourly expects a parameter


Expected results:
"foreman-maintain packages update" treats no parameter the same way as "yum update" does

Additional info:
Undocumented workaround is 
# foreman-maintain packages update \\*

Comment 4 Martin Bacovsky 2019-10-21 12:42:18 UTC
Created redmine issue https://projects.theforeman.org/issues/28097 from this bug

Comment 7 Bryan Kearney 2020-02-12 17:05:47 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/28097 has been resolved.

Comment 8 Lukas Pramuk 2020-03-04 15:14:48 UTC
VERIFIED.

@Satellite 6.7.0 Snap14
rubygem-foreman_maintain-0.5.2-1.el7sat.noarch

by following manual reproducer:

# foreman-maintain packages update
Running preparation steps required to run the next scenarios
================================================================================
Check if tooling for package locking is installed:                    [OK]
--------------------------------------------------------------------------------


Running update packages in unlocked session
================================================================================
Confirm update all is intentional: 

WARNING: No specific packages to update were provided
so we are going to update all available packages.
It is recommended to update everything only as part of upgrade
of the Satellite to the next version. 
To Upgrade to next version use 'foreman-maintain upgrade'.

NOTE: --assumeyes is not applicable for this check

Do you want to proceed with update of everything regardless
of the recommendations?, [y(yes), q(quit)] y
                                                                      [OK]      
--------------------------------------------------------------------------------
...

>>> "foreman-maintain packages update" treats no parameter the same way as "yum update" does

Comment 11 errata-xmlrpc 2020-04-14 12:58:36 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, 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-2020:1442


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