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 1464611 - Close file descriptor, flush buffers on grub.cfg and directory before exiting
Summary: Close file descriptor, flush buffers on grub.cfg and directory before exiting
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: grubby
Version: 7.5
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Peter Jones
QA Contact: Release Test Team
URL:
Whiteboard:
Depends On:
Blocks: 1466036
TreeView+ depends on / blocked
 
Reported: 2017-06-23 22:40 UTC by François Cami
Modified: 2023-09-07 18:53 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1466036 (view as bug list)
Environment:
Last Closed: 2020-11-11 21:37:50 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description François Cami 2017-06-23 22:40:38 UTC
Description of problem:
Running grubby even to add kernel parameters to the command-line and then rebooting "hard" (power outage or open file descriptor in /boot) often results in boot issues.
Booting manually, or mounting (and playing the journal) of the /boot filesystem repairs the issue most of the time.


Version-Release number of selected component (if applicable):
grubby-0.28-17.el7
though looking at upstream ( https://github.com/rhboot/grubby ) all versions up to and including 34b1436ccbd56eab8024314cab48f2fc880eef08 seem problematic.


How reproducible:
Nearly always.


Steps to Reproduce:
1. Create a RHEL7 VM called rhel7-vm in KVM, with IP=192.168.122.10
2. Run "ssh root@$192.168.122.10 grubby --args elevator=deadline --update-kernel DEFAULT && virsh destroy rhel7-vm"
3. Run "virsh start rhel7-vm"

Actual results:
VM is stopped at grub prompt due to a missing grub.cfg configuration file: this is typically repaired by a filesystem journal replay.


Expected results:
VM boots.


Additional info:
writeConfig() doesn't close its configuration file before rename() is called, nor when/before the process exits successfully. 

fsync() is not called on the configuration file nor on the configuration directory.

Comment 2 François Cami 2017-06-23 22:44:37 UTC
Upstream PR: https://github.com/rhboot/grubby/pull/24

Comment 7 Chris Williams 2020-11-11 21:37:50 UTC
Red Hat Enterprise Linux 7 shipped it's final minor release on September 29th, 2020. 7.9 was the last minor releases scheduled for RHEL 7.
From intial triage it does not appear the remaining Bugzillas meet the inclusion criteria for Maintenance Phase 2 and will now be closed. 

From the RHEL life cycle page:
https://access.redhat.com/support/policy/updates/errata#Maintenance_Support_2_Phase
"During Maintenance Support 2 Phase for Red Hat Enterprise Linux version 7,Red Hat defined Critical and Important impact Security Advisories (RHSAs) and selected (at Red Hat discretion) Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available."

If this BZ was closed in error and meets the above criteria please re-open it flag for 7.9.z, provide suitable business and technical justifications, and follow the process for Accelerated Fixes:
https://source.redhat.com/groups/public/pnt-cxno/pnt_customer_experience_and_operations_wiki/support_delivery_accelerated_fix_release_handbook  

Feature Requests can re-opened and moved to RHEL 8 if the desired functionality is not already present in the product. 

Please reach out to the applicable Product Experience Engineer[0] if you have any questions or concerns.  

[0] https://bugzilla.redhat.com/page.cgi?id=agile_component_mapping.html&product=Red+Hat+Enterprise+Linux+7


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