This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 296361 - (nash-relatime) [PATCH] nash mount should support relatime
[PATCH] nash mount should support relatime
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: mkinitrd (Show other bugs)
rawhide
All Linux
low Severity high
: ---
: ---
Assigned To: Peter Jones
Fedora Extras Quality Assurance
: Reopened
: 426423 426573 430280 475495 478330 (view as bug list)
Depends On:
Blocks: F11Blocker/F11FinalBlocker
  Show dependency treegraph
 
Reported: 2007-09-19 10:06 EDT by Curtis Doty
Modified: 2009-05-06 12:34 EDT (History)
19 users (show)

See Also:
Fixed In Version: 6.0.71-4.fc10
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-02-04 15:50:03 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Patch against fedora 7 CVS to add relatime support to nash (3.16 KB, patch)
2007-10-07 11:20 EDT, Stu Tomlinson
no flags Details | Diff
Patch against fedora devel CVS to add relatime support to nash (3.06 KB, patch)
2007-10-07 11:21 EDT, Stu Tomlinson
no flags Details | Diff
adapt earlier patch for F10 mkinitrd (1.49 KB, patch)
2009-01-04 17:06 EST, Jayson King
no flags Details | Diff
adapt earlier patch for F10 mkinitrd (1.77 KB, patch)
2009-01-04 18:36 EST, Jayson King
no flags Details | Diff

  None (edit)
Description Curtis Doty 2007-09-19 10:06:08 EDT
Edit /etc/fstab and make your root fs use relatime. Then install a new kernel
and reboot...

The initrc appears to succceed with:

 mkrootdev -t ext3 -o relatime,ro /dev/vg1/root

But then chokes on the next line:

 mount /sysroot
Comment 1 Stu Tomlinson 2007-10-07 11:20:54 EDT
Created attachment 218711 [details]
Patch against fedora 7 CVS to add relatime support to nash
Comment 2 Stu Tomlinson 2007-10-07 11:21:34 EDT
Created attachment 218721 [details]
Patch against fedora devel CVS to add relatime support to nash
Comment 3 William H. Haller 2007-10-30 21:13:45 EDT
The just released 2.6.23.1-10 kernel also panics with either LVM or direct 
extfs3 file systems that have had /etc/fstab set with nodiratime,relatime as 
options on / and /boot.

Booting the previous 2.6.22.1-91 kernel and setting these options back to 
defaults in /etc/fstab has no effect.

Also did a remount of the live file systems in 2.6.22.1-91 to be just read 
write and executed a telinit 0 and reboot to the 23 kernel. Still gives a 
kernel panic after Unrecognized mount option relatime or missing value even 
when not in /etc/fstab.

No errors reported in 2.6.22.1-91 at all.
Comment 4 Stu Tomlinson 2007-10-30 21:40:36 EDT
This is not directly dependent on kernel version, but on the mount options
specified in /etc/fstab *at the time a kernel update is installed*.

I now know that relatime is actually the default now, so anyone encountering
this can remove relatime from their /etc/fstab and rebuild the initrd for their
kernel to avoid this bug (I still think the patch should be applied for safety),
and still have / mounted using relatime.

To rebuild your initrd you can run:
 /sbin/new-kernel-pkg --package kernel --mkinitrd --depmod --install 2.6.23.1-10
after removing the relatime flag from /etc/fstab. (This is probably an overkill
way of rebuilding the initrd, it may be sufficient to run:
 mkinitrd /boot/initrd-2.6.23.1-10.fc7.img 2.6.23.1-10.fc7
but I know the 1st command is what kernel rpm installs use).
Comment 5 William H. Haller 2007-11-04 15:56:10 EST
Thanks. Only one change was needed. The command line needs to be

/sbin/new-kernel-pkg --package kernel --mkinitrd --depmod --install 
2.6.23.1-10.fc7

I suspect that this is going to bite quite a few people in upgrading to F8. If 
relatime is the default (any word on noadir?) then it should be silently 
ignored if it's in /etc/fstab or perhaps generate a warning when the kernel 
upgrades and be silently ignored.
Comment 6 William H. Haller 2007-11-04 16:27:42 EST
Sorry - make that nodiratime and noatime on NFS. Is the atime change made in 
all instances or just relatime?
Comment 7 Warren Togami 2007-12-21 00:54:49 EST
*** Bug 426423 has been marked as a duplicate of this bug. ***
Comment 8 Michal Jaegermann 2007-12-21 11:52:51 EST
Oh, this is filed for F7 so a bugzilla search for duplicates in F8
missed it. :-)

I did not realize that 'relatime' is now a default.  Thanks.

OTOH I fully agree with a comment 1 to bug 426423 that this should
be fixed.  No good reasons for failed boots because somebody did
valid /etc/fstab edits.  Say you are running with / on a CF card
and you want to mount 'noatime' to cut down on writes.  This is
a "real life" example and those few things which care about a correct
atime may be not needed.  I do not know if 'noatime' will trip
mkrootdev from nash or not but something else will.

Is a stopgap measure of modifying kernel package scripts to
use '--rootopts=defaults' with mkinitrd somehow simpler?
Comment 9 Bug Zapper 2008-05-14 10:25:21 EDT
This message is a reminder that Fedora 7 is nearing the end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 7. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '7'.

Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 7's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 7 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug. If you are unable to change the version, please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. If possible, it is recommended that you try the newest available Fedora distribution to see if your bug still exists.

Please read the Release Notes for the newest Fedora distribution to make sure it will meet your needs:
http://docs.fedoraproject.org/release-notes/

The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 10 Stu Tomlinson 2008-05-14 10:33:14 EDT
This issue still exists in rawhide.
Comment 11 Peter Jones 2008-07-14 17:06:31 EDT
As relatime is the default, this shouldn't need to be set in fstab.  As such, we
also shouldn't need it in nash.
Comment 12 Curtis Doty 2008-07-14 17:13:30 EDT
It's your call. But I say, "harrumph!" Since a valid (albeit superfluous) mount
option shouldn't break a system.
Comment 13 Peter Jones 2008-07-14 17:24:51 EDT
*** Bug 426573 has been marked as a duplicate of this bug. ***
Comment 14 Jayson King 2009-01-04 16:50:34 EST
I recently ran into this as well. IMO nash should be able to handle relatime just as it handles the other flags (it does noatime, nodiratime, etc already). I adapted the patch here for F10, and it Just Works. Here are some thoughts that I have about this, though:

1) nash.c should include linux/fs.h, instead of defining its own MS_* constants.

2) mkinitrd should know about the flags that nash understands, and reject any that won't work, or at least warn the user.
Comment 15 Jayson King 2009-01-04 17:06:40 EST
Created attachment 328155 [details]
adapt earlier patch for F10 mkinitrd

I don't know if there is a compelling reason to define the MS_* constants explicitly, but here's a patch for F10 mkinitrd that is an adaptation of the earlier patch with the change that it replaces #define MS_* with #include <linux/fs.h>.

Tested on x86_64.
Comment 16 Jayson King 2009-01-04 18:36:55 EST
Created attachment 328162 [details]
adapt earlier patch for F10 mkinitrd

As long as we're including linux/fs.h we can get rid of the other MS_* defines also.
Comment 17 Warren Togami 2009-01-05 05:11:17 EST
*** Bug 430280 has been marked as a duplicate of this bug. ***
Comment 18 Warren Togami 2009-01-05 05:13:10 EST
While it is true that it is meant to be default, a valid option in fstab should NOT break nash's ability to boot the system.  This should be fixed in nash.
Comment 19 Hans de Goede 2009-01-06 05:11:56 EST
*** Bug 475495 has been marked as a duplicate of this bug. ***
Comment 20 Michael Cronenworth 2009-01-09 22:01:15 EST
XFS does not default to "relatime" so this breaks on people using XFS, such as myself, who want to use "relatime" in their fstab.
Comment 21 Michael Cronenworth 2009-01-09 22:01:30 EST
*** Bug 478330 has been marked as a duplicate of this bug. ***
Comment 22 Curtis Doty 2009-01-09 23:16:22 EST
Zing! Pop.

Peter, have we convinced you yet? Is there anything else we can do to help push a fix through?
Comment 23 Hans de Goede 2009-02-04 15:50:03 EST
Hi all,

I'm terrible sorry this took us so long. This is fixed in mkinitrd-6.0.76, which will be in the next rawhide push.
Comment 24 Matthew Woehlke 2009-02-04 15:57:30 EST
Thank you! Do you plan to push this to F10 at least (after suitable testing)? I'd like to be able to test it against my asus (bug 478878).
Comment 25 Hans de Goede 2009-02-04 16:06:17 EST
(In reply to comment #24)
> Thank you! Do you plan to push this to F10 at least (after suitable testing)?
> I'd like to be able to test it against my asus (bug 478878).

Yes the plan is to include this in the next mkinitrd update for F-10 which will be soonish.
Comment 26 Fedora Update System 2009-03-09 19:10:37 EDT
mkinitrd-6.0.71-4.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 27 Jeremy Katz 2009-05-06 12:34:55 EDT
*** Bug 475495 has been marked as a duplicate of this bug. ***

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