bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error booting diag partition on T42 laptop


From: Peter Jones
Subject: Re: Error booting diag partition on T42 laptop
Date: Wed, 05 Oct 2005 16:29:44 -0400

On Wed, 2005-10-05 at 16:01 -0400, G. Vincent Castellano wrote:
> Thanks for a prompt reply.  I'll need some clarification on some of your 
> points, 
> though it sounds to me like this is going to be too much work to fix.
> 
> Peter Jones wrote:
> > On Wed, 2005-10-05 at 09:24 -0400, G. Vincent Castellano wrote:
> > 
> >>I have an IBM T42 laptop which includes a diagnostics/restore partition and 
> >>I
> >>want to be able to boot this from Grub, as well as the XP and RedHat 
> >>partitions.
> >>
> >>I started out by booting from a RedHat install CD, deleted the Windows XP 
> >>partition, and added  Linux Swap and ext2 filesystems, then I was able to 
> >>use 
> >>the diag/recovery partition to restore XP to the space remaining.  I can 
> >>boot 
> >>into XP and RedHat no problem, but not to the Diag partition.
> > 
> > This happens because the kernel brokenly disables the Host Protected
> > Area, and during some OS installation you've wiped the MBR and written a
> > new one with disk geometry read from the disk.
> 
> That would be the RedHat install.

Well, it would be a combination of the Red Hat install and some other
actions that have been taken.  By default we get the drive geometry from
the MBR, and at least on my T41 IBM ships their MBRs to reflect the disk
size when HPA is enabled.  The kernel disables HPA, but we don't read
the disk geometry from the drive directly unless there's no valid data
in the MBR.

So something has blown away the data entirely (which could be "zerombr"
in a kickstart file, but again that's not the default behavior), and
then you've run the installer, and it's asked the disk for the size,
which we've honored the data we got back.  There's really no way to tell
that this isn't the right thing to do from userland right now, so this
is as close as we can do to "correct" behavior until the kernel is
fixed.

> > There's really no way to "undo"; the data is gone so you need to get it
> > from IBM.  Even then, the same kernel bug plus the userland and
> > installer's ignorance will probably bite you.
> 
> I had enough foresight to build myself a set of recovery CDs before I started 
> this exercise so I can get back the original factory config.  But it doesn't 
> sound like there is an easy way to achieve the desired result.

No, probably not -- the filesystem is likely using some parts of the
disk that used to be the "Protected Area".  Note that the kernel
disables HPA at during boot, and in a nonvolatile way.  So it
re-disables it every time.  You should see a message in your dmesg like:

hda: Host Protected Area detected.
        current capacity is 110194034 sectors (56419 MB)
        native  capacity is 117210240 sectors (60011 MB)
hda: Host Protected Area disabled.
hda: 117210240 sectors (60011 MB) w/7877KiB Cache, CHS=65535/16/63, UDMA(100)

Once it says "Host Protected Area disabled.", the capacity the disk
returns is the "native" capacity; beforehand it would be the "current"
capacity.

> Maybe I will try the recovery CDs and see if they offer any options for the 
> reinstallation, though I would be surprised if this were the case.

They might -- but you'll probably need to shrink and/or move the FS and
the partition it's on first.

> What if I decline to install grub from the RedHat CD and instead do it 
> manually? 

This isn't really a grub problem; it's a kernel problem that affected
what happened during installation.

>   Would that afford any means of preserving the HPA?

Nope.  The data is already gone.
-- 
  Peter





reply via email to

[Prev in Thread] Current Thread [Next in Thread]