RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 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 "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". 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 "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-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 1210294 - [RFE] request for subscription-manager to support filtering auto-attach pools using matches
Summary: [RFE] request for subscription-manager to support filtering auto-attach pools...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: subscription-manager
Version: 7.3
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: rc
: ---
Assignee: candlepin-bugs
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-09 11:10 UTC by Rich Jerrido
Modified: 2020-12-11 11:48 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-03-31 10:12:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1246270 1 None None None 2021-01-20 06:05:38 UTC

Internal Links: 1246270

Description Rich Jerrido 2015-04-09 11:10:24 UTC
Description of problem:

Newer versions of subscription-manager (>=1.13.7), a user can invoke a command to search for a matching subscription. 

Example would be:

subscription-manager list --available --matches 'Awesome*'

Which would show all the pools that match 'Awesome'


This RFE requests extending the 'attach' subcommand such that the user can attach the matching subscriptions with one command. Proposed example would be


subscription-manager attach --available --matches 'Awesome*' 


This would support this use case:


"As a user, I know I need a sub that provides RHEL, RHSCL & Satellite
(because the documentation says so), I may not have any/all of them installed yet (thus no product certs in /etc/pki/product) and I am deferring the decision making to you (subscription-manager) because you are better at it than me"

After invoking the proposed command, (which would give us a much shorter list of pools to work with) we'd run through a process similar
to auto-attach, where we consult the systems facts, host/guest
relationship, SLA preference, etc. to *attempt* to pick the most appropriate
pool, (I.e. a virtual guest should preferably consume from its
hypervisors pool before consuming a unit/instance based sub).  Failing
gracefully with 'you don't have a sub that matches what you asked for'
is totally appropriate.

Comment 2 John Sefler 2015-04-09 13:13:19 UTC
Let me try and rephrase the request...

The syntax for the new function would be...

# subscription-manager attach --auto --matches 'Awesome*' 
or now that --auto is the default behavior starting in subscription-manager-1.14)
# subscription-manager attach --matches 'Awesome*'

Under the covers, candlepin's algorithm would be something like this...
  1a. search through all of the engineering product (Names and IDs) that are provided by the currently available pools for this consumer
  1b. assume that the matching engineering products are installed
  2a. search through all of the subscription pools (Names, SKU, Contract, Service Level) that are currently available for this consumer
  2b. assume that *all* of the product Ids provided by the matching subscriptions are installed
  3.  run the auto binding algorithm against only the union of assumed installed products from 1b and 2b.


Reference on matches: https://bugzilla.redhat.com/show_bug.cgi?id=1146125#c7

Comment 7 Barnaby Court 2017-08-21 14:10:31 UTC
This is specifically for adding the ability to use the --matches flag with the auto-attach to filter the pools that will be considered for auto-attch.

Comment 8 Rehana 2020-03-31 10:12:56 UTC
Thank you for your request. With the improvements we have done to the subscribe experience in the recent years with the introduction of new features like System purpose and enablement of simple content access.  We don't believe this request is needed to be delivered any more. We are therefore closing this out as WONTFIX. If you have any concerns about this, please feel free to reach out to us.


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