How do I restore a single partition?
-
aspenskier
- Posts: 6
- Joined: Tue Jun 04, 2013 7:53 pm
How do I restore a single partition?
I am using Image for Windows ~v2.65 to capture disk images which contain two partitions; one is the system partition and the 2nd is a data partition. I would like to be able to re-image these disks but only restore the system partition, not the data partition. The data partition really needs to remain unmolested by the imaging process.
When a drive is new/or needs to be cleaned I use a standard practice to remove any volumes and delete any partitions before I lay down the partitions; I specify the sizes as follows:
imagew.exe /r /f:i:\%imagename% /sp:1 /d:0 /clr /m /rs:%cpartitionsizeGB%000 /rb:0
imagew.exe /r /f:i:\%imagepath% /sp:2 /d:0 /m /x
Typically I'll do something like 100GB for a system partition and let the data partition fill the remaining disk space.
What I need to be able to do, but don't know how, is to restore just the system partition.
I've used imagew.exe /L /D:0 to show me the partition numbers, then imagew.exe /r /d:0@partition#, but this doesn't work. I'm prompted with a warning that ALL partitions will be wiped out. Does anyone have any guidance for me to follow here?
When a drive is new/or needs to be cleaned I use a standard practice to remove any volumes and delete any partitions before I lay down the partitions; I specify the sizes as follows:
imagew.exe /r /f:i:\%imagename% /sp:1 /d:0 /clr /m /rs:%cpartitionsizeGB%000 /rb:0
imagew.exe /r /f:i:\%imagepath% /sp:2 /d:0 /m /x
Typically I'll do something like 100GB for a system partition and let the data partition fill the remaining disk space.
What I need to be able to do, but don't know how, is to restore just the system partition.
I've used imagew.exe /L /D:0 to show me the partition numbers, then imagew.exe /r /d:0@partition#, but this doesn't work. I'm prompted with a warning that ALL partitions will be wiped out. Does anyone have any guidance for me to follow here?
-
TeraByte Support(PP)
- Posts: 1775
- Joined: Fri Aug 12, 2011 12:51 am
Re: How do I restore a single partition?
You need to include the /sp option to specify the partition to restore:
imagew /r /d:0@0x1 /f:"backup image" /sp:0x1
If you don't specify the drive (/d), IFW will search for the source drive and use it as the target drive.
Keep in mind that you can setup the backup with the options you want using IFW and then click the "Show Command" button on the "Restore Options" screen to see (or save) the command line.
imagew /r /d:0@0x1 /f:"backup image" /sp:0x1
If you don't specify the drive (/d), IFW will search for the source drive and use it as the target drive.
Keep in mind that you can setup the backup with the options you want using IFW and then click the "Show Command" button on the "Restore Options" screen to see (or save) the command line.
-
Bob Coleman
- Posts: 877
- Joined: Fri Aug 12, 2011 5:58 pm
Re: How do I restore a single partition?
From where are you running this thing? You can't, I don't think, restore the system partition from which you are running.
I, admittedly, can't really help you with IFW since I only use IFD. The command line parameters for IFD, and I guess IFW, can be somewhat esoteric, but it should be easy enough to restore a single partition via the IFD GUI if you have IFD.
I, admittedly, can't really help you with IFW since I only use IFD. The command line parameters for IFD, and I guess IFW, can be somewhat esoteric, but it should be easy enough to restore a single partition via the IFD GUI if you have IFD.
-
aspenskier
- Posts: 6
- Joined: Tue Jun 04, 2013 7:53 pm
Re: How do I restore a single partition?
I am working within WinPE via a network boot image.
Within this environment I have access to the hard disk drive, which contains both partitions, as well as a drive mapped to the location of the IFW executable file. The FAQs and KNOWLEDGE base are littered with posts like the scenario you reference, however that isn't what I'm trying to do.
My WinPE system partition lives on X:\
My Image For Windows lives on H:\
My source .TBI file lives on I:\
and I have a local disk with two partitions:
C:\ system
E?:\data
I simply want to run image for windows from H: and pull data from I: and put it down on C:, nothing more.
Within this environment I have access to the hard disk drive, which contains both partitions, as well as a drive mapped to the location of the IFW executable file. The FAQs and KNOWLEDGE base are littered with posts like the scenario you reference, however that isn't what I'm trying to do.
My WinPE system partition lives on X:\
My Image For Windows lives on H:\
My source .TBI file lives on I:\
and I have a local disk with two partitions:
C:\ system
E?:\data
I simply want to run image for windows from H: and pull data from I: and put it down on C:, nothing more.
-
TeraByte Support(PP)
- Posts: 1775
- Joined: Fri Aug 12, 2011 12:51 am
Re: How do I restore a single partition?
Version 2.65 is almost two years old. You should update to the current version.
IFW normally runs fine in WinPE. You just need to reference the drives as seen when booted into that environment (may be different from in Windows) or specify the drives by ID (e.g. disk signature) instead of number.
Assuming all drives are seen in WinPE, there shouldn't be a problem running IFW from H:, selecting the TBI file on I:, and restoring a partition from it to C:.
Are you trying to use the command line only? Have you tried using IFW normally (GUI) to restore the partition?
Are you using a custom built WinPE? If so, have you tried using TBWinPE/RE?
IFW normally runs fine in WinPE. You just need to reference the drives as seen when booted into that environment (may be different from in Windows) or specify the drives by ID (e.g. disk signature) instead of number.
Assuming all drives are seen in WinPE, there shouldn't be a problem running IFW from H:, selecting the TBI file on I:, and restoring a partition from it to C:.
Are you trying to use the command line only? Have you tried using IFW normally (GUI) to restore the partition?
Are you using a custom built WinPE? If so, have you tried using TBWinPE/RE?
-
aspenskier
- Posts: 6
- Joined: Tue Jun 04, 2013 7:53 pm
Re: How do I restore a single partition?
Thank you Paul,
I am using this older version because it is what shipped with the Landesk product that I am using to automate this process. While it is the windows version of the product I am using command lines only because I actually don't interact with the process at all once it kicks off.
I should be clear that I have no issues using this product in WinPE and it works quite well, its just that I'm trying to move forward with preserving my users' data partition and I've never done it before. My source TBI file contains 2 partitions and I only want to restore the system partition, C. I have used the product to identify the correct drive and partition numbers but when I try to run the command line to restore a single partition only I get a prompt from the GUI indicating that all partitions will be lost. I don't want to lose the data partition in the process.
What I'm looking for here is the correct command line parameters to restore the single partition without touching the other.
Does this make sense?
And to answer your questions, NO, I have not tried the GUI because this needs to be something driven without interaction and I didn't figure I would learn anything by going that route; My WinPE is custom to a limited degree as it contains some custom device drivers as well as other software, however I view it as mostly vanilla microsoft-I have no issues with it so I can't see how it factors into my current challenge with IFW.
I am using this older version because it is what shipped with the Landesk product that I am using to automate this process. While it is the windows version of the product I am using command lines only because I actually don't interact with the process at all once it kicks off.
I should be clear that I have no issues using this product in WinPE and it works quite well, its just that I'm trying to move forward with preserving my users' data partition and I've never done it before. My source TBI file contains 2 partitions and I only want to restore the system partition, C. I have used the product to identify the correct drive and partition numbers but when I try to run the command line to restore a single partition only I get a prompt from the GUI indicating that all partitions will be lost. I don't want to lose the data partition in the process.
What I'm looking for here is the correct command line parameters to restore the single partition without touching the other.
Does this make sense?
And to answer your questions, NO, I have not tried the GUI because this needs to be something driven without interaction and I didn't figure I would learn anything by going that route; My WinPE is custom to a limited degree as it contains some custom device drivers as well as other software, however I view it as mostly vanilla microsoft-I have no issues with it so I can't see how it factors into my current challenge with IFW.
-
TeraByte Support(PP)
- Posts: 1775
- Joined: Fri Aug 12, 2011 12:51 am
Re: How do I restore a single partition?
Have you tried what I posted in my first reply? Specifying the source partition (your example doesn't show that)?
imagew.exe /r /d:w1@0x1 /f:"I:\Backups\Whole_Drive" /sp:0x1
In this case, the GUI will prompt that all data on the listed partitions on HD1 will be lost and show the single partition being restored (ID 0x1, here).
The main reason I suggested using the GUI is to go through the steps and make sure it works. Also, you can use the GUI to show you the command line parameters to use for the operation.
imagew.exe /r /d:w1@0x1 /f:"I:\Backups\Whole_Drive" /sp:0x1
In this case, the GUI will prompt that all data on the listed partitions on HD1 will be lost and show the single partition being restored (ID 0x1, here).
The main reason I suggested using the GUI is to go through the steps and make sure it works. Also, you can use the GUI to show you the command line parameters to use for the operation.
-
aspenskier
- Posts: 6
- Joined: Tue Jun 04, 2013 7:53 pm
Re: How do I restore a single partition?
Okay, thanks
I'll give that a try.
I didn't know that the GUI would build the appropriate command line bits and then display it.
I'll give that a try.
I didn't know that the GUI would build the appropriate command line bits and then display it.
-
aspenskier
- Posts: 6
- Joined: Tue Jun 04, 2013 7:53 pm
Re: How do I restore a single partition?
Thank you again for the help, Paul.
I've just completed further testing and the GUI is doing what you said it would and I now have the command line that I need to automate the process.
My only remaining issue is "How do I suppress prompts from IFW relating to overwriting data on the drive?"
My imaging tasks are going to assume that I'm overwriting an existing partition but otherwise leaving the all important data partition alone. Once this is set I don't need the warnings anymore and I want them suppressed so that the process is fully automated. How can I suppress the warnings that IFW throws at me?
I've just completed further testing and the GUI is doing what you said it would and I now have the command line that I need to automate the process.
My only remaining issue is "How do I suppress prompts from IFW relating to overwriting data on the drive?"
My imaging tasks are going to assume that I'm overwriting an existing partition but otherwise leaving the all important data partition alone. Once this is set I don't need the warnings anymore and I want them suppressed so that the process is fully automated. How can I suppress the warnings that IFW throws at me?
-
TeraByte Support(PP)
- Posts: 1775
- Joined: Fri Aug 12, 2011 12:51 am
Re: How do I restore a single partition?
You would use one or more of the unattended options (/uy /un /ui /um). They're listed in the manual.
Use /uy to answer "Yes" to prompts.
Use /uy to answer "Yes" to prompts.