Monday, March 3, 2008

Adventures in MBR restoration

Backstory:
I'm trying to restore my old Acer to factory default settings before I ship it to the person that's buying it from me. Apparently putting Linux on my old Acer wiped out the MBR (master boot record) - which I'm cool with, I like the GRUB boot manager that comes with Ubuntu.

Even more backstory:
The MBR tells your computer how to boot. Most computers boot to one operating system. GRUB is a boot manager that lets you select what you want to boot then starts up the respective OS. The problem is, GRUB has to be installed to the MBR, so whatever was residing there previously (i.e., instructions to boot Windows) got wiped out.

Irrelevant backstory:
Ctrl+Shift in the blog input window switches between Preview and Edit mode, and it drives me nuts.  I use Ctrl+Shift to select blocks of text with the keyboard.  It's cramping my style, yo.  Word.

Back to the original backstory:
After dinking around for the past hour or two, I finally got the original Acer MBR back in action. The reason I needed to do this is because the ability to restore the entire computer to factory defaults relies on the Acer MBR being in place; if it's not in place, then the Alt+F10 key combination which is supposed to bring up the system restoration software, won't bring up JAAAACK SQUAAAT!  (Clever Chris Farley/Matt Foley reference, no?)

All that being said, I got the MBR back, and I'm hitting Alt+F10 to get my entire laptop reset, and a
Windows XP screen comes up as the startup splash screen.  Mind you, this is a Windows Vista computer.  Apparently it has two versions of Windows running on it.  Spiffy!  It's like Acer hacked up a copy of Windows XP and set it up to only perform the restoration process.

I'm going to write down everything I did so if I have to do this in the future I won't struggle trying to re-figure everything out.  Unless you're just curious, you might want to go ahead and stop reading this (unless you already have anyway).
Prerequisites:
a.  Windows partition is intact
b.  PQSERVICE (Acer restoration partition) is intact
c.  We have a Ubuntu Live CD
d.  We have internets
If all that is good, then it's time to start cooking.
1.  Boot into Ubuntu with a Live CD.
2.  Go to System > Administration > Software Sources
3.  Enable the "Universe" repository.  Let it refresh the repositories so it will know ms-sys is available.
4.  Install ms-sys:  "sudo apt-get install ms-sys"
5.  If the hard drive you're booting from is /dev/sda, then run "sudo ms-sys -m /dev/sda".  As far as I know, you can't run it for a particular partition (i.e. sda1).
6.  While you're in Ubuntu, copy the "RYTOOLS" directory from the "PQSERVICE" restoration partition to the root directory of your "ACER" partition.  By default, the partition Acers boot from is called "ACER".
At this point, we have fixed the MBR so that Windows can boot, and have grabbed all of the utilities necessary to restore Acer's custom MBR.  Now we just need to run it.
7.  Restart the computer.  While it is booting, hit F8 repeatedly to bring up Windows' boot menu.
8.  Select the "Repair Windows" option (that's not word for word, but it does have something about repair in it).
9.  Select the command prompt option.  This will bring up a Windows terminal window.
10.  Run "cd \RYTOOLS".  This will put you in the restoration utility directory you copied over while in Ubuntu.
11.  Run "mbrwrwin.exe install rtmbr2.bin".  This command does the actual custom Acer MBR installation.
12.  Reboot your computer.  You should be able to hit Alt+F10 to restore it to default factory settings.
WARNING:  I read how someone used a method somewhat similar to this and they accidentally jacked up their Windows partition.  I think they did some other things to mess up their computer aside from running mbrwrwin.exe.  Since we're just modifying the MBR and not touching the actual data, the only thing we can really do is make Windows unbootable.  So, if you're just wanting Windows to boot and don't care about getting the restoration functionality in place, just run the ms-sys commands in Ubuntu above and that should be good.

And now my old laptop has finished restoring and is getting everything set up for it's second first-time run.  Thank you internets!

3 comments:

raequin said...

Thank You, internets. I am going to try this on my ACER today. We'll see ...

used computers said...

It uses what Acer call their CrystalBrite technology. I personally really enjoy using the screen, and Vista have their screen fonts slightly larger than XP's were for better readability.

Unknown said...

This site use full to all around the would, use it develop both.........
this site use of all the would and system news and helps known every one...........

System Restoration