Bug 583351 - dracut ignores fstab.sys when setting up root
Summary: dracut ignores fstab.sys when setting up root
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dracut
Version: 12
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Harald Hoyer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-04-18 02:23 UTC by Ian Dall
Modified: 2010-10-30 23:39 UTC (History)
2 users (show)

Fixed In Version: dracut-005-5.fc12
Clone Of:
Environment:
Last Closed: 2010-10-27 22:54:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
A new dracut module to implement fstab.sys handling (511 bytes, application/octet-stream)
2010-04-18 02:42 UTC, Ian Dall
no flags Details

Description Ian Dall 2010-04-18 02:23:38 UTC
Description of problem:
Using the old mkinitrd, root would be set up by the nash "setuproot" command which would refer to fstab.sys (if it exists) for a list of things to mount. In particular this allowed /var to be on a separate filesystem (either local or nfs). With dracut, the root setup is done with a bunch of shell scripts and fstab.sys is ignored.

Version-Release number of selected component (if applicable):
dracut-004-4

How reproducible:
Always

Steps to Reproduce:
1.Create an entry in /etc/fstab AND /etc/fstab.sys for /var on the root filesystem for an nfsroot client
2.Boot client
3.ls /var/lib/nfs/rpc_pipefs
  
Actual results:
/var/lib/nfs/rpc_pipefs is empty

Expected results:
/var/lib/nfs/rpc_pipefs is not empty

Additional info:
The problem is that /var has been overmounted after the sunrpc filesystem has been mount --moved. This has bad consequences for nfs4 idmapd. It also creates problems if readonly-root is in use because the bind mounts created through the rwtab and statetab magic are overmounted.

Comment 1 Ian Dall 2010-04-18 02:42:27 UTC
Created attachment 407343 [details]
A new dracut module to implement fstab.sys handling

This module implements fstab.sys handling. This has to happen after the root mount and before the nfsroot-cleanup pre-pivot at least. I've made to happen at the beginning of the pre-pivot scripts, although it should maybe be at the end of the mount scripts. This latter would be harder to do because the actual mount is currently done by 99mount-root.sh and there is no 2 digit integer higher than 99 :-(

There are perhaps other ways of achieving this end, such as having the nfsroot-cleanup trawl through the newroot's /etc/fstab and auto-magically figure out if there are any mounts which are pre-requisites for the /var/lib/nfs/rpc_pipefs mount and do them first. Likewise post pivot, /etc/rc.sysinit could figure out of there are any pre-requisite mounts for /var/lib/stateless/{writeable,state} before doing those mounts. In short, make it the responsibility of anything doing a mount to check if there are any pre-requisites in /etc/fstab and mount them first. However, this spreads the changes needed over more places, so I favour the fstab.sys approach. Also, who knows what other uses administartors may have put fstab.sys to? and this undoes a regression caused by the move from mkinitrd to dracut.

Comment 2 Fedora Update System 2010-09-23 15:31:17 UTC
dracut-005-4.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/dracut-005-4.fc13

Comment 3 Fedora Update System 2010-09-23 15:32:46 UTC
dracut-005-4.fc12 has been submitted as an update for Fedora 12.
https://admin.fedoraproject.org/updates/dracut-005-4.fc12

Comment 4 Fedora Update System 2010-09-24 20:38:26 UTC
dracut-005-4.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update dracut'.  You can provide feedback for this update here: https://admin.fedoraproject.org/updates/dracut-005-4.fc12

Comment 5 Fedora Update System 2010-10-27 22:53:16 UTC
dracut-005-5.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2010-10-30 23:37:54 UTC
dracut-005-5.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.


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