How to clone a HD - Page 2


Page 2 of 2 FirstFirst 12
Results 16 to 24 of 24

Thread: How to clone a HD

  1. #16
    Join Date
    Oct 2002
    Location
    Way down yonder in the land of cotton...
    Posts
    274
    ok.. ths seems like the apporpriate place to ask this.... what if I wanted to clone a 10 GB partition over to a 160 GB partition? can I do that?
    I have a friend that has a working Win2K system on a 10 GB hard drive and she's looking to get a 160GB hard drive and for some odd reason doesn't want to go the normal route of backing up and reinstalling. Can I clone the hard drive into one 160 GB partition?
    one by one, the penguins steal my sanity...

    Registered Linux User#: 340703

  2. #17
    Join Date
    Nov 2003
    Posts
    40
    man you guys are doing this the hardway. you don't need any fancy shmancy tools to copy info in linux. Get a bootable linux cd , like knopix, and boot your system with it. then backup your system

    cd to the root partition you want to save
    tar cvjpf BACKUP_LOCATION_PATH/backup.tar.bz2 *

    you can dump the tar to any partition, or just keep it around as a backup.

    tar xvjpf backup.tar.bz2 -C PATH_TO_NEW_PARTITION

  3. #18
    Join Date
    Apr 2001
    Location
    SF Bay Area, CA
    Posts
    14,936
    Originally posted by jot-87
    But with Linux I can use any number of primary partitions, right?
    Only if you use some partition table format other than the standard MS-DOS one.

    Basically, anything in the kernel's "File systems --> Partition Types --> Advanced partition selection" menu might work. I've never looked at any of their on-disk formats other than MS-DOS, though, so I'm not sure. The Solaris-x86 option might work, as might the BSD disklabel option. But you'd have to figure out how to write that partition table to your disk, and converting will not be easy.

    Therefore, I'd say live with the limit on primary partitions. (That's why there are logical partitions, anyway -- to put more than 4 partitions on a single disk.) It's not really that bad.

  4. #19
    Join Date
    Oct 2003
    Location
    WV
    Posts
    298
    Originally posted by jrbishop79
    ok.. ths seems like the apporpriate place to ask this.... what if I wanted to clone a 10 GB partition over to a 160 GB partition? can I do that?
    I have a friend that has a working Win2K system on a 10 GB hard drive and she's looking to get a 160GB hard drive and for some odd reason doesn't want to go the normal route of backing up and reinstalling. Can I clone the hard drive into one 160 GB partition?
    You can dl a trial version of Norton Ghost (I think they still have a trial) and put the 160GB in as a slave and clone to it, then after you are done, reverse the two drives, format the 10 and use it as a secondary for extra storage.
    Sometimes when I reflect back on all the beer I drink I feel ashamed - Then I look into the glass and think about the workers in the brewery and all of their hopes and dreams. If I didn't drink this beer, they might be out of work and their dreams would be shattered. Then I say to myself, "It is better that I drink this beer and let their dreams come true than be selfish and worry about my liver."

    -Deep Thought, Jack Handey

  5. #20
    Join Date
    Feb 2004
    Location
    Singapore
    Posts
    2,170
    you can use partimage for it. (10GB to 160GB)

    in fact, dd can be done too, just that you have to use qtparted to extend the partition to 160 GB
    Come under the reign of the Idiot King...
    Come to me ... I love linux!

    Registered Linux user: Idiot King #350544

  6. #21
    Join Date
    Jan 2004
    Location
    boston, mass USA
    Posts
    1,878
    One major issue to overcome is that windows doesn't like drives over 130gigs, especially as boot devices.

    My aproach would be to break the new drive down into 2 partitions, then use Norton Ghost to image 10gig to 30gig partition, then format the extra 100gig remaining for data (and just forget about 30 gigs 'cause i have a network server for data anyway, but thats me!)

    Thats also good for reinstalls of OS since data is safe on 2nd partition.


    Also, regarding primary partitions:

    It isn't a limit of the OS is it? IDE (?) standards is 4 primary partitions, unless you want more. Then 1-3 are primary and usable, 4 is primary and unusable except to hold more logical paritions 5-x. So the OS would see 1,2,3,5,6,7,8,xxx but not really #4
    Last edited by happybunny; 01-15-2005 at 01:21 AM.

  7. #22
    Join Date
    Apr 2001
    Location
    SF Bay Area, CA
    Posts
    14,936
    Originally posted by happybunny
    It isn't a limit of the OS is it?
    It's a limit of the tools provided with the OS, so therefore I assume it's a limit of the OS itself. IIRC, DOS fdisk won't let you create more than one primary partition.

    IDE (?) standards
    It's actually not IDE. IDE controls the way the drive talks to the rest of the computer, not the data on the drive. The standard you mean is the one that describes partition table layout on the drive -- it's the partition table format.

    is 4 primary partitions, unless you want more.
    You can't have more. 4 primary partitions is IT, PERIOD.

    Then 1-3 are primary and usable, 4 is primary and unusable except to hold more logical paritions 5-x. So the OS would see 1,2,3,5,6,7,8,xxx but not really #4
    Not necessarily...

    OK, I'll back up a little. The on-disk format for a partition table is a set of 4 records, each one 16 bytes long, plus two marker bytes. This data goes in the last 66 bytes of the MBR (the marker bytes are 0x55 and 0xAA, but they may be in the other order). Each record describes a single partition.

    There is only physical space in the partition table for 4 of these records, therefore there is NO WAY to get more than 4 of what I'll call "first-level" partitions.

    One of the 16 bytes in the data structure describing each partition is a "partition type" byte. There are various standards for what different values in this byte mean. One value means FAT32 with LBA. Another value means Linux data partition (any FS). Another value means Linux swap partition (although Linux itself can use any partition as swap-space, this is usually the type that most distro installers will give to the swap partition, if you create one). Another value means extended partition.

    Any first-level partition, other than an extended partition, is a primary partition.

    Therefore, the absolute maximum imposed by the layout of the partition table, is four primary partitions.

    Now, all partition types have a pointer to the start of the partition (and most of them, perhaps all, have a length field also). This sector is the boot record of the partition in question, and for logical partitions (which are housed inside an extended partition -- the first sector of the extended partition is actually also the first sector of the first contained logical partition), it contains another partition table. This partition table has only one entry, which points at the start (and gives the length) of the next logical partition.

    No partitioning tool I've ever used has allowed more than one extended partition, but this isn't important, because the logical partitions inside the extended one basically form a linked list. So you can have as many logical partitions as your OS can support. (In the case of Linux, that's 59 -- because the block device minor number for a disk has 6 bytes allocated to partition number, and the other 2 bytes allocated to which disk it's on. That leaves 63 possible partitions, because number 0 is reserved for the whole disk. 4 of them are also reserved for primary partitions (1-4), leaving room for 59 logicals.)

    However, there's also nothing requiring you to use all four primary partition slots (and this is why I said "not necessarily" above). My hda, for example, has only two first-level partitions (one is extended, the other is primary), but it has 7 logical partitions inside that. Those logical partitions host three installations of LFS (2 partitions each, for root and /var), plus a /home partition.

  8. #23
    Join Date
    Jan 2004
    Location
    boston, mass USA
    Posts
    1,878
    I have never been so corrected in my life!

    Great feedback. Since every OS i remember using only allows 1-4 primary, or 1-3ish primary and the rest logical contained within the 4th primary, I always asssssumed it was a hardware restriction, not OS specifically.

    I also never thought about using extended partitions without using up all the primaries first.

    I hate learning new stuff so early in the day!

  9. #24
    Join Date
    Oct 2003
    Location
    WV
    Posts
    298
    bwkaz,

    I have got to take my hat off to you. Your replies are always very informative, well written, and factual. (I have even researched some of the ones I wasn't sure about just to check.) People like you are why I keep coming here time after time.

    Long live JL.
    Sometimes when I reflect back on all the beer I drink I feel ashamed - Then I look into the glass and think about the workers in the brewery and all of their hopes and dreams. If I didn't drink this beer, they might be out of work and their dreams would be shattered. Then I say to myself, "It is better that I drink this beer and let their dreams come true than be selfish and worry about my liver."

    -Deep Thought, Jack Handey

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •