Bug 191381 - CDrom media unmounted before %post script gets run
CDrom media unmounted before %post script gets run
Product: Fedora
Classification: Fedora
Component: anaconda (Show other bugs)
All Linux
medium Severity high
: ---
: ---
Assigned To: Chris Lumens
Mike McLean
Depends On:
  Show dependency treegraph
Reported: 2006-05-11 10:23 EDT by Philip Prindeville
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-05-16 10:29:37 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Patch to defer releasing filesystem (or filesystem image) (660 bytes, patch)
2006-05-15 12:32 EDT, Philip Prindeville
no flags Details | Diff

  None (edit)
Description Philip Prindeville 2006-05-11 10:23:45 EDT
Description of problem:

If you try to access /mnt/source in a %post script when installing from CDrom,
the media will already have been unmounted by the time %post is run... leading
to failure.

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

How reproducible:

Put "mount" with no args in the %post script.

Steps to Reproduce:
1. Build a CD installer disk with "mount" in the %post script.
2. Reboot
Actual results:

The output will not show /mnt/source being mounted.

Expected results:

It should be mounted until the system is ready to reboot.

Additional info:
Comment 1 Philip Prindeville 2006-05-15 12:32:52 EDT
Created attachment 129091 [details]
Patch to defer releasing filesystem (or filesystem image)

Still not clear to me why unmountCD() needs to be present in all methods, or
why there is so much duplication of functionality between filesDone (for the CD
install method, at least) and unmountCD().

Perhaps unmountCD() should be a private method of the CD installer that gets
called from the subclassed version of filesDone()?

Anyway, this patch simply calls filesDone() a lot later in the install process,
after postInstall() has been invoked.
Comment 2 Chris Lumens 2006-05-15 15:23:07 EDT
Committed that fix and we'll see how well it works in the next anaconda build. 
The duplication is due to how the repo stuff works between anacond and yum -
should be changing quite a bit before FC6.  Note that you're only going to have
the last CD available here, so this is probably only most useful for NFS or DVD

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