Bug 12631 - Installer adds installation media to /etc/fstab - installed system does not boot without install media
Summary: Installer adds installation media to /etc/fstab - installed system does not b...
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: Installer (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: release_blocker critical
Target Milestone: Mageia 5
Assignee: Thierry Vignaud
QA Contact:
URL:
Whiteboard:
Keywords:
: 11869 13463 15378 (view as bug list)
Depends on:
Blocks: 14069
  Show dependency treegraph
 
Reported: 2014-02-06 15:11 CET by Florian Hubold
Modified: 2015-03-31 15:04 CEST (History)
8 users (show)

See Also:
Source RPM:
CVE:
Status comment:


Attachments
/root/drakx/report.bug.xz from the affected system (302.73 KB, application/x-xz)
2014-02-06 15:13 CET, Florian Hubold
Details

Description Florian Hubold 2014-02-06 15:11:51 CET
Description of problem:

This already happened multiple times. A user installed Mageia 4 from a flash drive, and afterwards he needed to figure out why it doesn't boot properly, only drops to recovery console. It only booted when the flash drive was plugged.

Turned out that the installer added the install media to /etc/fstab:

# Entry for /dev/sdb1 :
UUID=92F7-1AA6 /mnt/hd vfat umask=000,iocharset=utf8 0 0


Cannot think of any commonly used scenario where adding normal installation media to /etc/fstab would not be harmful.

The other bug in here is that installer never uses nofail option for anything it adds to fstab which is not critical to Mageia - as for NTFS partitions. Why should Mageia boot fail when some windows partition cannot be mounted or when their UUID changed because they have been formatted? No impact on Mageia. Same for this bug: Even if it's useless to add an entry for installation media, would the installer have used nofail, the entry would still be wrong altogether bug the boot would have succeeded.

Please fix.

Reproducible: 

Steps to Reproduce:
Comment 1 Florian Hubold 2014-02-06 15:13:19 CET
Created attachment 4948 [details]
/root/drakx/report.bug.xz from the affected system

/root/drakx/report.bug.xz from the affected system

CC: (none) => doktor5000

Manuel Hiebel 2014-02-06 16:37:14 CET

Assignee: bugsquad => thierry.vignaud

Florian Hubold 2014-02-07 21:56:38 CET

See Also: (none) => https://bugs.mageia.org/show_bug.cgi?id=4042

Comment 2 Florian Hubold 2014-02-07 22:16:29 CET
FWIW, here are some of the occurences I've seen so far:

https://forums.mageia.org/en/viewtopic.php?f=15&t=4810
https://forums.mageia.org/de/viewtopic.php?f=7&t=1976
https://forums.mageia.org/en/viewtopic.php?f=7&t=6920

This prevents users from testing and obviously using Mageia, marking as release_blocker for 5.

Target Milestone: --- => Mageia 5
Priority: Normal => release_blocker
Version: 4 => Cauldron
Severity: major => critical

Comment 3 David Remy 2014-03-01 19:46:32 CET
Also FWIW, this seems to be an issue that has been around since MGA2 in various incarnations. Looks like the following three bugs are related to this

https://bugs.mageia.org/show_bug.cgi?id=9317
https://bugs.mageia.org/show_bug.cgi?id=3550
https://bugs.mageia.org/show_bug.cgi?id=11869

CC: (none) => dpremy

Florian Hubold 2014-05-17 18:43:25 CEST

See Also: (none) => https://bugs.mageia.org/show_bug.cgi?id=10179

Comment 4 Manuel Hiebel 2014-05-31 10:08:25 CEST
*** Bug 11869 has been marked as a duplicate of this bug. ***

CC: (none) => pf

Comment 5 Manuel Hiebel 2014-05-31 10:08:39 CEST
*** Bug 13463 has been marked as a duplicate of this bug. ***
Florian Hubold 2014-09-08 23:05:14 CEST

Blocks: (none) => 14069

Comment 6 w unruh 2014-11-21 17:28:09 CET
How can earlier bugs by duplicates of a later bug? and that none of those are resolved, as they report themselves to be. 

Anyway, this is far more than simply an installer bug. The bug is that the system hangs if anything in fstab is unmountable. An external drive, a partition whose uuid has been renumbered. The problem is that systemd refuses to proceed if there are any errors in the mount process. While not being able to mount / or /usr is obviously a showstopper, not mounting /wigglesworth should NOT be a showstopper. 
And simply putting a nofail into the fstab line so the lack of mounting is not reported is not a fix, it is a poor bandaid, and means the user is never actually informed that some of his partitions have not mounted.

CC: (none) => unruh

Comment 7 Florian Hubold 2014-11-21 22:09:24 CET
(In reply to w unruh from comment #6)
> How can earlier bugs by duplicates of a later bug? and that none of those
> are resolved, as they report themselves to be. 

Duplicates are automatically linked to the "master" bug and set to RESOLVED DUPLICATE - that's how it works. For explanation see https://bugs.mageia.org/page.cgi?id=fields.html#status
Mostly the master bug is the one with the most information.

> And simply putting a nofail into the fstab line so the lack of mounting is
> not reported is not a fix, it is a poor bandaid, and means the user is never
> actually informed that some of his partitions have not mounted.

This bug is about the installer adding removable media to fstab, which should not happen. There are other bugs for similar issues for a running system (UUID change, or network filesystem not marked as _netdev or nofail)

What do you propose to fix _this_ installer bug, or prevent this from happening?

For your described issue check https://bugs.mageia.org/show_bug.cgi?id=10179
and/or https://bugs.mageia.org/show_bug.cgi?id=12305 for those issues.
Comment 8 w unruh 2014-11-22 03:15:54 CET
They are all part and parcel of the same bug in systemd (I think)-- namely that it demands that all partitions in /etc/fstab be mountable for the system to complete the boot. 
If that overarching bug were not there, then having the installation medium in fstab, having a uuid break on a partition, or any of the other problems would not be a boot problem, but a problem that could be fixed from within a running system. 
 
One can band-aid every subsidiary problem that that bug causes, "fixing" things here or there, or one can fix the real bug. Ie, without the real bug, having the installer add removable media to fstab might still be a bug, but it would be a minor one, with virtually no consequences, rather than a show-stopper.

Regarding the "duplicate" I just found it strange that an early bug would be marked as duplicate of a late bug, rather than the other way around. It does not really matter much, except the earliest one claimed that this bug (adding installation media into fstab) was solved 3 years ago, yet here it still is.
Comment 9 Florian Hubold 2014-11-23 13:37:16 CET
(In reply to w unruh from comment #8)
> They are all part and parcel of the same bug in systemd (I think)-- namely
> that it demands that all partitions in /etc/fstab be mountable for the
> system to complete the boot.

If you don't specify any options, that would be correct and also expected behaviour. Although it could fail much more gracefully in simply skipping non-system mounts if they fail.

But _this bug_ is the wrong place to discuss this. The problem is known and existent, if you want to improve that fact send in patches to fix it, and attach them to the other bugs.

> If that overarching bug were not there, then having the installation medium
> in fstab, having a uuid break on a partition, or any of the other problems
> would not be a boot problem, but a problem that could be fixed from within a
> running system. 

Those are still two different bugs. The installer should never put any removable media in fstab, that is just harmful - even for older non-systemd installations.
Comment 10 w unruh 2014-11-26 19:19:09 CET
Note that when I recently installed Mageia 4.1 from a usb stick, the usb stick was not added to /etc/fstab. Does that mean that this problem (installation medium added to fstab) has been solved, or was I just lucky? The installation medium WAS still added to /etc/urpmi/urpmi.conf which is only a bit sensible, but at least does not cause boot problems.
Comment 11 Anne Nicolas 2014-12-15 00:35:40 CET
Is this bug still valid for last isos?

CC: (none) => ennael1

Comment 12 Florian Hubold 2015-01-21 19:59:28 CET
(In reply to Anne Nicolas from comment #11)
> Is this bug still valid for last isos?

Did not occur again, but I've not installed a lot of systems in between.

Status: NEW => RESOLVED
Resolution: (none) => FIXED

Comment 13 Michael Riss 2015-03-31 02:36:40 CEST
I have this problem again in Mageia 5 Beta 3. 
It's on a UEFI system (Asrock Z97 Extreme 4, UEFI version P1.80).
I copied the classic installation media with isodumper onto a USB stick (FAT32 with UEFI setting). 
After the installation in UEFI mode the system has the USB stick listed in its fstab and the "storage scan" waits for the timeout duration of 1min 30sec during boot. 
When I manually remove the entry from the fstab or keep the USB media inserted the boot process has no delay.

Status: RESOLVED => REOPENED
CC: (none) => Michael.Riss
Resolution: FIXED => (none)

Comment 14 Michael Riss 2015-03-31 02:45:40 CEST
*** Bug 15378 has been marked as a duplicate of this bug. ***

CC: (none) => tarazed25

Comment 15 claire robinson 2015-03-31 10:15:20 CEST
This should be fixed now in current RC ISO builds.

http://gitweb.mageia.org/software/drakx/commit/?id=745849cdace7ed86ce12a9a7564bffb42edf0ef3

Closing again, but please reopen if you still experience the problem with the RC when its released.
Rémi Verschelde 2015-03-31 10:16:38 CEST

CC: (none) => remi

Comment 16 Thierry Vignaud 2015-03-31 15:04:33 CEST
Actually I think this one got fixed by:
http://gitweb.mageia.org/software/drakx/commit/mdk-stage1/NEWS?id=d590e8727f7274119df1f9e98adc11aca6aafaaa
(after beta 3).
Really closing

Status: REOPENED => RESOLVED
Resolution: (none) => FIXED


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