Bug 504743 - BUG - liveinst does not take into account drive still needs to be partitioned.
BUG - liveinst does not take into account drive still needs to be partitioned.
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: anaconda (Show other bugs)
11
All Linux
low Severity medium
: ---
: ---
Assigned To: Jeremy Katz
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-06-09 02:24 EDT by Traxtopel
Modified: 2009-06-25 16:11 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-06-25 16:11:28 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Traxtopel 2009-06-09 02:24:42 EDT
Description of problem:

boot livecd, start liveinst, choose entire drive, or replace existing linux partitions, install will always fail with

Your / partition does not match the "
                            "the live image you are installing from.  "
                            "It must be formatted as %s."

The problem I see is that the check happens before any partitioning has actually taken place, so indeed it is wrong.
Patch should also check whether replace or entire has been selected.
Comment 1 Traxtopel 2009-06-09 02:37:06 EDT
To work around this, currently I am using. Probably wrong since ext3 vs ext4 could get mixed up. 

--- /usr/lib/anaconda/storage/__init__.py.orig	2009-06-09 08:33:54.377206015 +0200
+++ /usr/lib/anaconda/storage/__init__.py	2009-06-09 08:34:20.951206156 +0200
@@ -830,13 +830,13 @@
                             productName))
 
         # livecds have to have the rootfs type match up
-        if (root and
-            self.anaconda.backend.rootFsType and
-            root.format.type != self.anaconda.backend.rootFsType):
-            errors.append(_("Your / partition does not match the "
-                            "the live image you are installing from.  "
-                            "It must be formatted as %s.")
-                          % (self.anaconda.backend.rootFsType,))
+#        if (root and
+#            self.anaconda.backend.rootFsType and
+#            root.format.type != self.anaconda.backend.rootFsType):
+#            errors.append(_("Your / partition does not match the "
+#                            "the live image you are installing from.  "
+#                            "It must be formatted as %s.")
+#                          % (self.anaconda.backend.rootFsType,))
 
         for (mount, size) in checkSizes:
             if mount in filesystems and filesystems[mount].size < size:
Comment 2 Traxtopel 2009-06-09 03:05:17 EDT
Sorry wrong patch.
Adding the following "if not CLEARPART_TYPE_LINUX and not CLEARPART_TYPE_ALL:" seems to work for me.

--- /usr/lib/anaconda/storage/__init__.py.orig	2009-06-09 08:33:54.377206015 +0200
+++ /usr/lib/anaconda/storage/__init__.py	2009-06-09 09:03:41.922956258 +0200
@@ -830,13 +830,15 @@ class Storage(object):
                             productName))
 
         # livecds have to have the rootfs type match up
-        if (root and
-            self.anaconda.backend.rootFsType and
-            root.format.type != self.anaconda.backend.rootFsType):
-            errors.append(_("Your / partition does not match the "
-                            "the live image you are installing from.  "
-                            "It must be formatted as %s.")
-                          % (self.anaconda.backend.rootFsType,))
+	# However do not check if we are using clearpart
+	if not CLEARPART_TYPE_LINUX and not CLEARPART_TYPE_ALL:
+          if (root and
+              self.anaconda.backend.rootFsType and
+              root.format.type != self.anaconda.backend.rootFsType):
+              errors.append(_("Your / partition does not match the "
+                              "the live image you are installing from.  "
+                              "It must be formatted as %s.")
+                            % (self.anaconda.backend.rootFsType,))
 
         for (mount, size) in checkSizes:
             if mount in filesystems and filesystems[mount].size < size:
Comment 4 Jeremy Katz 2009-06-10 16:21:06 EDT
Urgh, same code block was needed in two different places for partitions vs logical volumes.  Patch sent for review
Comment 5 Jeremy Katz 2009-06-25 16:11:28 EDT
And committed

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