Comment 12 for bug 693671

Revision history for this message
Colin Watson (cjwatson) wrote :

I'm working on this.

My first step was to replace Wubi's built-in copy of grldr (originally from GRUB4DOS, as noted by bcbc) with the version available in the ntldr-img grub-extras branch, which is built as an add-on to GRUB 2. (There's a little work to do to allow that to be used for Wubi, but that's the least of my worries right now.) This suffered from the same problem, but at least this way I'm working with code where I have upstream commit access and something resembling an ongoing maintenance commitment. I'm thus going to handle this as though it were a grub2 bug.

Next, having got to the point of being able to repeatedly build, install, and test modified versions of wubildr.mbr, I started trying to insert debug code. This is very difficult due to the constraints in place here. NTLDR only loads 8192 bytes from disk, and grldr must fit within that (which is why we can't just use GRUB 2 directly here, as even the most minimal GRUB 2 kernel is somewhat too big for this); it only allocates 2048 bytes for the NTFS bootstrap code, and we're very close to the limit here.

So far, I have got to the point of determining that it's calling the NTFS_Corrupt_Error function and failing. There are ten calls to this in ntfsbs.S, and I'm bisecting to find out which it is. After that I will have to figure out how to determine why. The process is very time-consuming.