Bug 871104 - Installer allows use of preexisting root filesystem
Summary: Installer allows use of preexisting root filesystem
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: anaconda
Version: 18
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: David Lehman
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: AcceptedNTH
Depends On:
Blocks: F18Beta-accepted, F18BetaFreezeExcept
TreeView+ depends on / blocked
 
Reported: 2012-10-29 16:01 UTC by David Lehman
Modified: 2012-11-08 09:38 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-11-08 09:38:37 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description David Lehman 2012-10-29 16:01:56 UTC
Description of problem:
Anaconda currently allows users to set as root a filesystem that existed prior to installation, which has been disallowed since F15 (see bug 629311).

Version-Release number of selected component (if applicable):
anaconda-18.21.-1

How reproducible:
Always

Steps to Reproduce:
1. Create a filesystem (ext4 or xfs)
2. Run the installer
3. Set the fs from step 1 as '/' but do not mark for reformat
  
Actual results:
Installer will happily try to install to the preexisting rootfs and will fail miserably if there is actually a previous installation on it.

Expected results:
Installer does not allow this highly dubious operation.

Additional info:
I have a tested patch ready to send out for review.

Comment 1 Paul Franklin (RHlists) 2012-10-31 17:45:57 UTC
For many years I have created an empty filesystem before
I installed a Fedora on it.  Will your patch allow that?

If not, can I ask that you modify your patch to allow it?

Thanks.

Comment 2 Adam Williamson 2012-10-31 18:22:38 UTC
Discussed at 2012-10-31 NTH review meeting: http://meetbot.fedoraproject.org/fedora-qa/2012-10-31/f18beta-blocker-review-6.2012-10-31-16.00.log.txt . Accepted as NTH as this is a safe and clearly desirable change. For the record, the patch is https://lists.fedorahosted.org/pipermail/anaconda-patches/2012-October/001824.html . 

Paul, I don't believe that would be a problem, this bug only intends to duplicate the pre-F18 behaviour.

Comment 3 Kamil Páral 2012-10-31 18:24:42 UTC
Please think about people (like me) who doesn't have /home on a separate partition. There can be many reasons for that, e.g. a small disk (SSD for example). When I want to reinstall the system, I remove all directories except /home and then set the partition as / without reformatting it.

I wasn't using Anaconda back then, but installers from other distributions. The last time I needed to do it with Anaconda, the partitioning shuffling was pretty difficult, because Anaconda insisted on formatting /.

David, can Anaconda guard against bad uses cases (as in your original description) and still allow the one I just described?

Comment 4 Adam Williamson 2012-11-01 01:10:49 UTC
"Please think about people (like me) who doesn't have /home on a separate partition. There can be many reasons for that, e.g. a small disk (SSD for example)."

Funnily enough, we have this great thing called 'LVM', which we use by default, which lets you easily adjust the size of different partitions, making this really not a big problem. You can install with a 10GB / and a 30GB /home or whatever, and adjust the ratios between them online without losing data later on if it turns out you need to.

My personal take is that your use case is a dumb one which we shouldn't support. We can't support _everything_.

Comment 5 Fedora Update System 2012-11-01 02:51:04 UTC
anaconda-18.22-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.22-1.fc18

Comment 6 David Lehman 2012-11-01 13:36:47 UTC
(In reply to comment #1)
> For many years I have created an empty filesystem before
> I installed a Fedora on it.  Will your patch allow that?
> 
> If not, can I ask that you modify your patch to allow it?

My patch will not allow it. This was not allowed in Fedora 17, either.

If you really need non-default arguments passed to mke2fs you can either use kickstart (see the fsprofile option) or use an updates image to modify /etc/mke2fs.conf.

I realize we could support this in theory, but it involves writing a significant chunk of code to support a use-case that we already support in other ways (see above). It just isn't likely to bubble up to the top of anyone's todo list for that reason.

Comment 7 Fedora Update System 2012-11-01 18:26:34 UTC
Package anaconda-18.22-1.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing anaconda-18.22-1.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-17432/anaconda-18.22-1.fc18
then log in and leave karma (feedback).

Comment 8 Fedora Update System 2012-11-02 04:05:33 UTC
anaconda-18.23-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.23-1.fc18

Comment 9 Fedora Update System 2012-11-03 01:05:00 UTC
anaconda-18.24-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.24-1.fc18

Comment 10 Fedora Update System 2012-11-06 01:40:11 UTC
anaconda-18.25-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.25-1.fc18

Comment 11 Fedora Update System 2012-11-07 02:12:06 UTC
anaconda-18.26-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.26-1.fc18

Comment 12 Adam Williamson 2012-11-08 09:38:37 UTC
18.26 went stable. Closing. (Bodhi closing of bugs when updates go stable is currently broken).


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