So I have a new machine at work to setup. It came with windows 7 on a 1tb drive. We ordered another smaller drive (250gb) to have the operating system on and use the 1tb drive as a large data drive. In the past I routinely connect both dries in the same box, boot from linux fedora live cdrom, go into a terminal and run the command
dd if=/dev/sda of=/dev/sdb
Which routinely clones bit for bit the first drive to the second drive.
Now for the fun part. In the past this has almost always been going from a smaller drive to a larger drive. After the successful copy, I would remove the small drive, boot into Gparted cdrom and manually resize non-destructively the partition to fill the entire drive.. or at least make larger.
For the first time I am going the other way.. larger to smaller drive.
Trying it out of the box failed with a “not enough room” error.
I noted that windows 7 can non-destructively resize itself under certain conditions so I booted into the 1tb drive windows 7, told it to shrink itself down to 200gb and it did in a minute or so. There were two other partitions on the drive, a small 100mb boot partition? and a larger recovery partition at the other end.
Ran the dd command thinking that it would only copy the existing partitions and no the new, large empty space created by the shinking partition in the middle. and in about 5 hours it was done without errors.
removed the 1tb leaving the 250gb drive in place, boot and it does start up and windows does start to work… then fails, reboots into its repair options and we cannot get any further, as the repair options to do not work either. I suspect they are looking to a spot farther up the old large drive in the partition table.
oh well.. that idea did not work. reformat from scratch and reinstall!