Bug 557989 - Can't upgrade FC 10 to FC 11: "Dirty file systems"
Can't upgrade FC 10 to FC 11: "Dirty file systems"
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: anaconda (Show other bugs)
12
athlon Linux
low Severity high
: ---
: ---
Assigned To: David Lehman
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-01-22 18:24 EST by Steve
Modified: 2011-11-30 11:37 EST (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-10-03 23:34:14 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
My hardware configuration, i.e. the output from "udevinfo --export-db" (2.70 KB, application/x-bzip2)
2010-01-22 18:24 EST, Steve
no flags Details
Install logs, as requested (22.39 KB, application/x-bzip2)
2010-01-25 11:17 EST, Steve
no flags Details
Install logs, as requested (23.31 KB, application/x-bzip2)
2010-02-04 19:34 EST, Steve
no flags Details
Untested patch to fix this issue, for current anaconda git HEAD (1.32 KB, patch)
2011-11-29 19:47 EST, Robert Vogelgesang
no flags Details | Diff

  None (edit)
Description Steve 2010-01-22 18:24:04 EST
Created attachment 386260 [details]
My hardware configuration, i.e. the output from "udevinfo --export-db"

I have a machine that had Fedora Core 10 installed on it fresh (i.e. on a blank hard drive).  When I try to upgrade to Fedora Core 11, I get to the point where it asks me which Linux installation I want to upgrade, I select the existing one, and it tells me I have "Dirty file systems", and lists my Linux installation's root filesystem (i.e. /dev/sda5) as dirty.

It's not dirty.  It's fine.  I can boot it and all is well.  I even tried running e2fsck on all my Linux partitions from FC11 rescue mode, in case something had changed between FC10 and FC11, but I still have the same problem.

I'm more than happy to provide additional information, or run test scripts or whatever, to identify the problem.  I've attached the output of "udevinfo --export-db" to this report; if there's a better way to explain my hardware configuration, please let me know.

Here's my filesystem layout (from "df"):

Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/sda3            181847760   5446280 167164108   4% /
/dev/sda6             55345184    285524  52248288   1% /tmp
/dev/sda5             55345184   3139272  49394540   6% /home
/dev/sda1                77749     15811     57924  22% /boot
/dev/sdb1            962571764 337406360 625165404  36% /video
/dev/sdb2            500575900  76295592 424280308  16% /data
tmpfs                  1687252      1160   1686092   1% /dev/shm

Thank you for your attention to this.  I'd love to upgrade but can't.
Comment 1 Hans de Goede 2010-01-25 03:31:12 EST
Please try to upgrade again, and once you hit the error, switch to tty2
(ctrl + alt + F2), and collect all the log files under /tmp. You can use for example scp to get the from there, and then attach them here.
Comment 2 Steve 2010-01-25 11:17:23 EST
Created attachment 386664 [details]
Install logs, as requested

I ended up installing FC 12 fresh on the machine I mentioned earlier.  However, I have another FC 10 machine that's having the same problem.  Attached are the install logs from that attempt.  Sorry for the unnecessary complication, but I got "motivated" this weekend :-)

Let me know if you need more info on that machine, e.g. the HW dump or the exact partitioning layout.  (Its partitioning is similar to the one I reported originally.)  Again, sorry for the unnecessary complication.
Comment 3 Steve 2010-01-28 17:25:37 EST
Was that information sufficient?  Do you need any more?
Comment 4 Hans de Goede 2010-01-29 08:01:20 EST
Hmm,

So it seems that libext2fs does not like your filesystem.

Can you try the following to confirm that that really is the problem:
-start the F-12 installer (on the same system as you used in comment #2)
-when add the GUI welcome screen switch to tty2 (ctrl + alt + F2)
-on this terminal execute:
cd /usr/lib/anaconda/
python
-and then at the python prompt type
import _isys
print _isys.e2dirty("/dev/sda5")

And then report back here with the output of those python commands.

Note if you are using a 64 bit install, the cd command should be:
cd /usr/lib64/anaconda/

Regards,

Hans
Comment 5 Steve 2010-01-29 12:19:50 EST
If I execute that command at any point from the first X Windows screen to just before selecting the existing Fedora Core installation to upgrade, it prints "0".  Once I select the existing Fedora Core installation to upgrade, and I get the "Dirty file systems" message, it prints "1".

Let me know what other information I can provide.
Comment 6 Hans de Goede 2010-01-30 11:28:42 EST
<ugh>

So we are doing something to the filesystem making it seen as marked dirty by the time we do the check (maybe we have it mounted at the time ?). I'm not very familiar with this part (upgrade path) of the code, so I'm going to assign this to a team member.

Dave if you're not the right person for this please re-assign to whomever is.

Regards,

Hans


p.s.

Steve have you considered upgrading directly to F-12, chances are this issue is fixed there ?
Comment 7 Steve 2010-01-30 23:49:58 EST
I didn't feel safe skipping a version, so I was trying to use FC 11.
But I tried FC 12 for the heck of it and the same thing happens, yes.

I'm willing to assist you in any way to track down this problem, but since I haven't gone through all the fun of learning anaconda, I need your assistance. :-)
Comment 8 David Lehman 2010-02-04 18:43:35 EST
It looks like we never unmount sda5 after mounting it on /mnt/sysimage to check if it's an upgradable root filesystem.

Please attach the logs from your attempt with F12 -- they may help us to see what is happening.

Thanks.
Comment 9 Steve 2010-02-04 19:34:08 EST
Created attachment 388935 [details]
Install logs, as requested

Here are the logs from an attempted FC12 upgrade, as requested.
Comment 10 Bug Zapper 2010-04-28 07:45:14 EDT
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  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 '11'.

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 11'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 11 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 to the applicable version.  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.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 11 Steve 2010-04-28 22:56:20 EDT
Since it happens in FC 12, and FC 11 is nearing end-of-life, I updated the bug to say FC 12.
Comment 12 syrenswyrd 2010-05-12 10:06:54 EDT
Very interested in seeing this resolved as I am encountering the same issue.  In my case, I'm trying a straight upgrade from F10 to F12 via preupgrade.  By the way, running a df in the alternate console shows that the offending partition (in my case /dev/sda1) is still mounted to /mnt/sysimage.  Possibly confirms what was posited earlier.
Comment 13 Steve 2010-07-05 19:49:03 EDT
So is there anything I can do about this problem?

I tried upgrading the same machine to FC 13 using preupgrade, but you can see bug 598389 for info on how that went.
Comment 14 Robert Vogelgesang 2010-08-08 16:19:10 EDT
Today I hit is bug when using preupgrade to upgrade my Eeepc from Fedora 12 to 13.

I was able to work around the bug by doing the following:

o  "unpacked" the downloaded install.img using
        unsquashfs install.img
   This creates a new directory named "squashfs-root" in the current directory.

o  Edit squashfs-root/usr/lib/anaconda/upgrade.py, search for "allowDirty = 0"
   and change the 0 to 1.  This change lets anaconda ignore the fact that the
   filesystem was detected as "dirty".

o  re-create an install image:
        mksquashfs squashfs-root install.img

o  Make sure that the upgrade will use the modified install.img instead of the
   original one.

Try this at your own risk; YMMV.  You need the squashfs-utils package, which
provides both the unsquashfs and mksquashfs commands.

Since my Eeepc has only 8 GB onboard flash storage, I had to use an extra USB memory stick for this procedure, but it worked nevertheless, even loading the
modified install.img from this USB stick.
Comment 15 Steve 2010-09-12 02:05:04 EDT
(In reply to comment #14)
> Today I hit this bug when using preupgrade to upgrade my Eeepc from Fedora 12
> to 13.

I tried the same thing today with my FC 12 system, and your suggestion was key to getting around the "Dirty file systems" problem!  I have some additional info, though.

1) I had to disconnect all my non-system hard drives, in order to avoid other weird installation bugs.

2) The package is actually called squashfs-tools, not squashfs-utils.

3) My installation died when the computer locked up while switching between X Windows and the virtual consoles.  My computer does that commonly when I don't boot with "nomodeset", but the current FC13 xorg-x11-drv-nouveau won't let X Windows start up if the machine was booted with "nomodeset", so I had no choice.

I ended up with an unusable system that was half-upgraded to FC13.  Bottom line, I had to reinstall Linux from scratch, so I didn't get to fully test your suggestion.  But I still think it was a good suggestion, so thank you.
Comment 16 Bug Zapper 2010-11-03 20:10:31 EDT
This message is a reminder that Fedora 12 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 12.  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 '12'.

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 12'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 12 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 to the applicable version.  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.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 17 Bug Zapper 2010-12-03 18:57:20 EST
Fedora 12 changed to end-of-life (EOL) status on 2010-12-02. Fedora 12 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 18 Steve 2011-10-03 23:09:54 EDT
Still happens under FC 14.
Comment 19 David Lehman 2011-10-03 23:34:14 EDT
The F16 Beta will be released at any time now. If you prefer upgrades over reinstalls, feel free to try using either F15 or the F16 Beta. The F14 installer is no longer being worked on. If you do have trouble upgrading related to dirty filesystems, please open a new bug. Feel free to mention this one, but this bug is too old -- it's time to let it die.
Comment 20 Rob 2011-11-28 23:59:55 EST
It concerns me greatly that this bug hasn't received due attention so that it is still present in the FC16 release.  That's SIX releases after it was initially reported!!!!  Kind of ridiculous, don't you think? 

It's bad enough that I had to remove all my mdadm software raid disks just to keep the anaconda install script from generating an unhandled exception during a device scan, but then even after doing so the upgrade path (either via network install CD or using the preupgrade package) tells me that my target ext4 root partition is dirty when it is clearly not dirty.

Come on guys, I understand that it's not intellectually stimulating to fix bugs but really, TWO YEARS and not seriously addressed!!!???

-Rob
Comment 21 Robert Vogelgesang 2011-11-29 19:47:23 EST
Created attachment 538332 [details]
Untested patch to fix this issue, for current anaconda git HEAD

About a year ago I developed a patch to fix this issue, but did not have the time or the opportunity to test it properly. As it seems, this issue is still not fixed, which triggered me to update the patch for the current anaconda git head.

The patch changes anaconda's pyanaconda/storage/__init__.py to delay read-write mounts until after the check for dirty file systems.  Maybe there are better methods to fix this issue in anaconda, but this was the most obvious one to me.

If you don't want to build an updated installer from scratch using a patched anaconda, you might try some trick based on my comment #14 and patch the file pyanaconda/storage/__init__.py of an existing installer image.

Note: I have NOT tested this patch; try it at your own risk. Feedback welcome.
Comment 22 Rob 2011-11-29 21:42:03 EST
The only .img file I have on my system, that I guess was deposited there by the preupgrade package installation, is /boot/upgrade/initrd.img and it doesn't contain any anaconda installation python scripts.  

I know absolutely nothing about anaconda or the build system you guys use to do installs.  And to be totally honest my biggest gripe about Fedora is that the developers change stuff way too frequently to try keeping up with it all.

I would have hoped that in bringing the problem to the attention of the development team a real patch would be pushed out to the repositories and "fixed" installation images would be posted.
Comment 23 Steve 2011-11-30 00:06:45 EST
Rob is right.  As of FC14, there's no longer an install.img, just an initrd.img, and it doesn't seem to be a squashfs, so the trick in comment #14 no longer works.

I upgraded to FC14 with "yum --releasever=14 -nogpgcheck update".  That works, but I'm unthrilled with having to disable GPG checking.  This method doesn't seem to install the GPG keys like preupgrade does, and I don't know how to make it do that.

BTW, bug 744953 is the one I had to file after comment 19 said I had to let this bug die, and it's being ignored too.
Comment 24 Steve 2011-11-30 11:37:58 EST
Looks like the fedora-release-14 package includes keys for FC15-17!  I was able to upgrade one of my computers from FC14 to FC16 with "yum --releasever=16 update"!

Afterwards, hald started freaking out, writing a bunch of messages to the console every few seconds, and wouldn't let me reboot cleanly, but otherwise, it worked!  No need to install fresh, and no need to struggle with preupgrade's bogus "dirty file systems".

So it seems there's a third option.

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