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 1159951 - [RFE] systemctl commands "add-wants" and "add-requires"
Summary: [RFE] systemctl commands "add-wants" and "add-requires"
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: systemd
Version: 7.0
Hardware: All
OS: Linux
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Lukáš Nykrýn
QA Contact: qe-baseos-daemons
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-11-03 17:01 UTC by Pat Riehecky
Modified: 2018-08-20 12:31 UTC (History)
4 users (show)

Fixed In Version: systemd-219-1.el7
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-19 15:01:32 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2092 0 normal SHIPPED_LIVE systemd bug fix and enhancement update 2015-11-19 12:13:57 UTC

Description Pat Riehecky 2014-11-03 17:01:21 UTC
Description of problem:
systemd 217 gained the following enhancement that would be useful for managing RHEL7 systems:

* systemctl gained two new commands "add-wants" and
"add-requires" for pulling in units from specific targets
easily

Version-Release number of selected component (if applicable):systemd-208-11.el7_0.4


How reproducible:100%


Steps to Reproduce:
1.This is a new feature backport request
2.
3.

Actual results:


Expected results:


Additional info:

Comment 2 Lukáš Nykrýn 2014-11-04 09:17:41 UTC
This is planned feature for 7.2.

Comment 3 Lukáš Nykrýn 2015-04-21 13:51:10 UTC
This should be now fixed with the rebase.

Comment 5 Radka Brychtova 2015-09-08 08:42:50 UTC
in systemd-219-13.el7.x86_64

systemctl add-requires TARGET NAME 
 add param "Requires=NAME" into TARGET    

  #systemctl show testscript.service| grep Wants
    Wants=cups.service system.slice
  #systemctl add-wants testscript.service cups
  #systemctl show testscript.service| grep Wants
   Wants=cups.service system.slice


systemctl add-wants TARGET NAME
  add param "Wants=NAME" into TARGET

  #systemctl show testscript.service| grep Requires
    Requires=basic.target
  #systemctl add-requires testscript.service cups
  #systemctl show testscript.service| grep Requires
    Requires=cups.service basic.target

Comment 6 errata-xmlrpc 2015-11-19 15:01:32 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://rhn.redhat.com/errata/RHBA-2015-2092.html


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