Fix Vista so a Repair is not needed after a restore or clone

Discussion in 'Acronis True Image Product Line' started by MudCrab, Sep 17, 2007.

Thread Status:
Not open for further replies.
  1. MudCrab

    MudCrab Imaging Specialist

    Joined:
    Nov 3, 2006
    Posts:
    6,483
    Location:
    California
    NOTE: The procedure below is required for TI 10 and earlier to be able to restore a Vista partition so that it does not require a repair. If you are using a version of TI later than 10 (TI 11, TI 2009, etc.), these changes are not needed as TI will make the necessary changes to the BCD file during the restore. However, if you wish to make the changes anyway to generalize Vista’s BCD entry so that it will boot from the Active partition (in preparation for duplicating a Vista partition, for example), the changes can be applied.

    If you have a Vista system that is installed to a Vista created partition, then most of you know that you have to restore the entire drive in order to avoid a repair. Restoring just the Vista partition will require a repair the first time it's restored. This is very undesirable, especially for those without a Vista DVD or BartPE CD.

    Mark (K0lo) has forwarded information to me along the same lines as what I was working on with repairing Vista using BartPE. (Thanks, Mark.) My method of repairing a Vista restore using BartPE can be found in this thread: How To Question - Restore and Eliminate one Partition starting at Post #14.

    I have tested this procedure with an image restore using both BartPE and the Full (Linux) version of TI (version 10, build 4,942) and they both restored a Vista created partition without needing to be repaired. Others have reported success with cloning.

    To prepare your Vista BCD file, start a Command Prompt in administrative mode (browse to the Command Prompt menu item, right-click and select Run as administrator):

    cmd_adm.jpg

    If the Command Prompt directory is not the \windows\system32 directory then type the following commands (<ENTER> means to press the ENTER key):
    Code:
    c: <ENTER>
    cd \windows\system32 <ENTER>
    If your Vista partition is a drive letter other than C: then use that drive letter.

    Once you're in the \windows\system32 directory, type the commands below:
    Code:
    bcdedit /set {default} device boot <ENTER>
    bcdedit /set {default} osdevice boot <ENTER>
    bcdedit /set {bootmgr} device boot <ENTER>
    bcdedit /set {memdiag} device boot <ENTER>
    This assumes that the "default" booting entry in the BCD file is Vista.
    After these changes, your bcdedit output will resemble this:
    Code:
    Windows Boot Manager
    --------------------
    identifier              {bootmgr}
    [COLOR="red"][B]device                  boot[/B][/COLOR]
    description             Windows Boot Manager
    locale                  en-US
    inherit                 {globalsettings}
    default                 {default}
    displayorder            {default}
    toolsdisplayorder       {memdiag}
    timeout                 30
    
    Windows Boot Loader
    -------------------
    identifier              {default}
    [COLOR="red"][B]device                  boot[/B][/COLOR]
    path                    \Windows\system32\winload.exe
    description             Microsoft Windows Vista
    locale                  en-US
    inherit                 {bootloadersettings}
    [COLOR="red"][B]osdevice                boot[/B][/COLOR]
    systemroot              \Windows
    resumeobject            {d5f6f061-52c6-11dc-8f68-ff6d008c462c}
    nx                      OptIn
    instead of referencing a partition directly as in the example below:
    Code:
    Windows Boot Manager
    --------------------
    identifier              {bootmgr}
    [COLOR="Red"][B]device                  partition=C:[/B][/COLOR]
    description             Windows Boot Manager
    locale                  en-US
    inherit                 {globalsettings}
    default                 {default}
    displayorder            {default}
    toolsdisplayorder       {memdiag}
    timeout                 30
    
    Windows Boot Loader
    -------------------
    identifier              {default}
    [COLOR="red"][B]device                  partition=C:[/B][/COLOR]
    path                    \Windows\system32\winload.exe
    description             Microsoft Windows Vista
    locale                  en-US
    inherit                 {bootloadersettings}
    [COLOR="red"][B]osdevice                partition=C:[/B][/COLOR]
    systemroot              \Windows
    resumeobject            {d5f6f061-52c6-11dc-8f68-ff6d008c462c}
    nx                      OptIn
    Now, if you clone the Vista partition or image it and restore it, you should not have to run a repair. It should boot up properly.

    I would be interested to hear any comments on this procedure.

    ---

    Note: I tested this procedure on a clean install of Vista Ultimate. There were no "recovery" partitions or "media direct" partitons, etc. If you are unsure about doing this procedure, I would recommend that you create an Entire Disk image (check the Disk # checkbox) before you make these changes. Then proceed to make the changes, then clone or reimage and restore. If it works properly, you can delete the backup images as you see fit.
     
    Last edited by a moderator: Dec 9, 2008
  2. 800ster

    800ster Registered Member

    Joined:
    Dec 1, 2006
    Posts:
    210
    Thanks, just tested this with a new install of Vista64 and it works as advertised.
     
  3. Menorcaman

    Menorcaman Retired Moderator

    Joined:
    Aug 19, 2004
    Posts:
    4,661
    Location:
    Menorca (Balearic Islands) Spain
  4. MudCrab

    MudCrab Imaging Specialist

    Joined:
    Nov 3, 2006
    Posts:
    6,483
    Location:
    California
    Great! And thanks for the feedback.
     
  5. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Here's one more tool to add to the arsenal. If you have already cloned or imaged your disk without having made the changes to BCD suggested by Paul, and you now need to do a repair, you can borrow a Vista DVD of any version. If you do not have access to any Vista DVD at all, there is another alternative.

    Microsoft has released a "Vista Anytime Upgrade" DVD that is designed to let Vista owners upgrade to a higher version by purchasing a license online. But the DVD contains all editions of Vista AND the repair components needed to do a repair operation.

    One source for this DVD is CompUSA and the cost is $5. It would be a good thing to have around for any PC owner who was not provided a Vista DVD by the manufacturer of their PC because it will let you repair your Vista installation should it ever become necessary.
     
  6. DwnNdrty

    DwnNdrty Registered Member

    Joined:
    Mar 28, 2007
    Posts:
    3,335
    Location:
    Florida - USA
    With WinXP there's a way of making your own XP install DVD if you have the i386 folder on your hard drive. Anyone know if a similar method exists for Vista?
     
  7. Hamah

    Hamah Registered Member

    Joined:
    Sep 4, 2007
    Posts:
    21
    Great work guys! I just hope TI 11 allows Vista users more ease, simplicity and reliability in the backup/restore process. Frankly these workarounds are WAY too difficult for the target market of True Image.
     
  8. DwnNdrty

    DwnNdrty Registered Member

    Joined:
    Mar 28, 2007
    Posts:
    3,335
    Location:
    Florida - USA
    Agreed Hamah ... you have to be at least part geek to do some of these workarounds. :D
     
  9. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Here's a post by a guy who did it (although specific to Lenovo laptops).
     
  10. jmk94903

    jmk94903 Registered Member

    Joined:
    Jul 10, 2004
    Posts:
    3,329
    Location:
    San Rafael, CA
    Code:
    Windows Boot Manager
    --------------------
    identifier              {bootmgr}
    [COLOR="red"][B]device                  boot[/B][/COLOR]
    description             Windows Boot Manager
    locale                  en-US
    inherit                 {globalsettings}
    default                 {default}
    displayorder            {default}
    toolsdisplayorder       {memdiag}
    timeout                 30
    
    Windows Boot Loader
    -------------------
    identifier              {default}
    [COLOR="red"][B]device                  boot[/B][/COLOR]
    path                    \Windows\system32\winload.exe
    description             Microsoft Windows Vista
    locale                  en-US
    inherit                 {bootloadersettings}
    [COLOR="red"][B]osdevice                boot[/B][/COLOR]
    systemroot              \Windows
    resumeobject            {d5f6f061-52c6-11dc-8f68-ff6d008c462c}
    nx                      OptIn
    MudCrab,

    Very slick piece of work.

    If you check after the repair with the Vista DVD, is this how the code looks?
     
  11. jmk94903

    jmk94903 Registered Member

    Joined:
    Jul 10, 2004
    Posts:
    3,329
    Location:
    San Rafael, CA
    I'm off to CompUSA. I'd rather not have to carry my Vista Ultimate DVD with me. I feel rather attached to it. :) This is a great alternative. Thanks!!!!
     
  12. MudCrab

    MudCrab Imaging Specialist

    Joined:
    Nov 3, 2006
    Posts:
    6,483
    Location:
    California
    John,

    No, it's not. Vista Repair seems to drop some of the parameters in the "Windows Boot Loader" section (locale, inherit, resumeobject and nx). It does not change the {bootmgr} device value (it leaves it as "unknown") and it changes the description parameter. The {default} device and osdevice parameters are set to the partition and not to the "boot" value.

    Code:
    Windows Boot Manager
    --------------------
    identifier              {bootmgr}
    [COLOR="Purple"][B]device                  unknown[/B][/COLOR]
    description             Windows Boot Manager
    locale                  en-US
    inherit                 {globalsettings}
    default                 {default}
    displayorder            {default}
    toolsdisplayorder       {memdiag}
    timeout                 30
    
    Windows Boot Loader
    -------------------
    identifier              {default}
    [COLOR="Red"][B]device                  partition=C:[/B][/COLOR]
    path                    \Windows\system32\winload.exe
    [COLOR="Blue"][B]description             Windows Vista (TM) Ultimate (recovered)[/B][/COLOR] 
    [COLOR="red"][B]osdevice                partition=C:[/B][/COLOR]
    systemroot              \Windows
     
  13. jmk94903

    jmk94903 Registered Member

    Joined:
    Jul 10, 2004
    Posts:
    3,329
    Location:
    San Rafael, CA
    Thanks. I was hoping for a simple answer. Silly me.:)
     
  14. jeremyotten

    jeremyotten Registered Member

    Joined:
    Feb 9, 2005
    Posts:
    684
  15. pdf

    pdf Registered Member

    Joined:
    Dec 14, 2006
    Posts:
    37
    So in essence this allows to use the 63 sector offset, instead of vista's new 2048 offset?
     
  16. phkhgh

    phkhgh Registered Member

    Joined:
    Aug 17, 2007
    Posts:
    186
    I'm not familiar w/ the Anytime Upgrade DVD. For purposes of doing this (or other) repair(s), NOT upgrades, will the DVD work w/o purchasing the online license?

    BIG question: many, including me, have a "Recovery Disk" which is an image of Vista (as I understand it), not the installation disk. Would the Anytime Upgrade disk work for REPAIRS on Vista installed (restored) from one of these Recovery disks?

    Also, is the "BCD" file found only in Vista?

    A lot of people have done great work here. Thanks. Acronis should be greatful!
     
    Last edited: Sep 18, 2007
  17. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Yes, the DVD will allow repairs without purchasing a license.

    As far as I know, Vista is the first Microsoft OS to use the BCD file instead of the older boot.ini file method.
     
  18. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    Vista has always happily installed to an existing partition with a 63-sector offset. The technique MudCrab described in this post allows the Vista partition to be moved without requiring a repair afterwards.
     
  19. MudCrab

    MudCrab Imaging Specialist

    Joined:
    Nov 3, 2006
    Posts:
    6,483
    Location:
    California
    I did read your post and I even downloaded your plugin (it's in my "Acronis" folder). I just didn't remember it. Sorry.

    However, your thread seems to imply using the plugin to repair Vista after it is broken. You make no mention of using it to fix Vista before a repair is needed. Maybe you weren't even aware at the time that it could be used that way. In any case, a "pre-repair" does not require BartPE as the user can do the procedure directly from Vista. Also, for those users without a BartPE CD, creating one without a working computer just to repair Vista may not an easy task, especially if they haven't made one before.
     
  20. phkhgh

    phkhgh Registered Member

    Joined:
    Aug 17, 2007
    Posts:
    186
    Think my earlier edit may have gotten lost in shuffle.
    If anyone has experience w/ this, I'd appreciate your 2 cents.
    Thanks again.
     
  21. K0LO

    K0LO Registered Member

    Joined:
    Mar 9, 2006
    Posts:
    2,591
    Location:
    State College, Pennsylvania
    I haven't tried that but it should work. The repair operation only needs to find an installation of Vista and that should not depend on whether it was installed by a retail DVD or by an OEM recovery disk.
     
  22. phkhgh

    phkhgh Registered Member

    Joined:
    Aug 17, 2007
    Posts:
    186
    Thanks KOlo.
    Looks like the Anytime Upgrade disk from CompUSA is only avail online, but apparently no shipping cost.
     
  23. jmk94903

    jmk94903 Registered Member

    Joined:
    Jul 10, 2004
    Posts:
    3,329
    Location:
    San Rafael, CA
    I tried our local CompUSA store and they didn't have it.

    I searched the CompUSA web site and couldn't find it listed. I came back here and used Mark's link and ordered two. Apparently, CompUSA hasn't told their search function that they have this. :) Could it be that they'd rather sell a $200 plus upgrade than a $5 disk that lets you order direct from Microsoft.
     
  24. appster

    appster Registered Member

    Joined:
    Jun 19, 2007
    Posts:
    561
    Location:
    Paradise
    MudCrab, I need to know if I really understand this statement... My PC running Vista Home Premium has 3 partitions (C, D, E) on its 1 physical drive (and I am using ATI v10 build 4942). Are you saying that by backing up C and D (to E) I will have to repair my C (Vista) partition if and when I restore it? :gack:
     
  25. MudCrab

    MudCrab Imaging Specialist

    Joined:
    Nov 3, 2006
    Posts:
    6,483
    Location:
    California
    appster,

    Yes, IF the Vista partition was created by Vista. If the partition was created by XP or DD or another third-party partition program, then you shouldn't have to repair.

    In your case, if you did a backup of your Entire Disk (C, D & E) and saved that image somewhere else (an external USB hard disk, for example), then if you restored that Entire Disk image you wouldn't have to run a Vista repair.

    If you follow the procedure outlined in Post #1 before you image and restore just your C: partition, then you should be able to restore without needing to do a repair.

    In other words, you may want to run the procedure so your Vista partition is prepared. Don't wait until the drive dies or a bad software install causes you to have to restore. By then, you'll have to use a Vista DVD or a BartPE CD (or a third-party BCD editor) to repair Vista.

    If you want to read up on the problem, it can be found in the link posted by Menorcaman in Post #3.
     
Thread Status:
Not open for further replies.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.