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 1512749 - grub2-setpassword ignores -o (--output_path) command line option
Summary: grub2-setpassword ignores -o (--output_path) command line option
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: grub2
Version: 7.4
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Peter Jones
QA Contact: Release Test Team
URL:
Whiteboard:
Depends On:
Blocks: 1477664 1571842
TreeView+ depends on / blocked
 
Reported: 2017-11-14 01:13 UTC by Sandeep MJ
Modified: 2022-03-13 14:32 UTC (History)
9 users (show)

Fixed In Version: grub2-2.02-0.68.el7
Doc Type: Bug Fix
Doc Text:
Cause: The -o option to grub2-setpassword was documented but never implemented. Consequence: The user may become confused about how to use the tool. Fix: Implement -o support. Result: Behavior matches existing documentation.
Clone Of:
Environment:
Last Closed: 2018-10-30 11:36:23 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:3264 0 None None None 2018-10-30 11:37:44 UTC

Description Sandeep MJ 2017-11-14 01:13:13 UTC
Description of problem:
Unable to specify the path to which user.cfg is to be written to.

Version-Release number of selected component (if applicable):
grub2-tools-minimal-2.02-0.65.el7_4.2.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Specify directory:
[root@r74 ~]# grub2-setpassword -o /home/
Enter password: 
Confirm password:


Actual results:
[root@r74 ~]# ls -l /home
total 0


Expected results:
[root@r74 ~]# ls -l /home
-rw-------  1 root root  298 Nov 14 00:59 user.cfg

Additional info:
Bug 1460530 was reported for Fedora 25, and contains a proposed fix

Comment 2 Bernie Hoefer 2018-05-04 22:18:28 UTC
Not sure how this fact should be documented in this ticket (if at all), but this problem has also been present in Fedora Linux since version 25.  Please see:

  BZ 1460530, "grub2-setpassword -o handling is broken"
  <https://bugzilla.redhat.com/show_bug.cgi?id=1460530>

Comment 4 Alexander Todorov 2018-07-23 13:22:34 UTC
# grub2-setpassword -o /home/
Enter password: 
Confirm password: 
grep: /home//grub.cfg: Няма такъв файл или директория
WARNING: The current configuration lacks password support!
Update your configuration with grub2-mkconfig to support this feature.

# ls -l /home/
общо 4
drwx------. 2 test test  76 18 юли  2,18 test
-rw-------. 1 root root 298 23 юли  9,21 user.cfg

# cat /home/user.cfg 
GRUB2_PASSWORD=grub.pbkdf2.sha512.10000.B9C8B3C9D2715889F50B8B60E57E88E70446F962B43AB50A7B9AE48DA56985B8B123177E2CDFB1BC313CFD983FAA56FFC4B8AC9343FACB621C4CAFC301ADE80F.23A930D142D5FFEE25B7D5306EB5B10D60B15BABBF4C84FB8D0291E3329E41AE354329F4457EEAC6193387CB03334B4EDC4C3CF05F2F277DC54E787592A3DB4B

# rpm -q grub2
grub2-2.02-0.73.el7.x86_64

Comment 8 errata-xmlrpc 2018-10-30 11:36:23 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-2018:3264


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