Menu

Restoring disk with difficult resize problem

Help
2009-03-04
2013-04-05
  • Daniele Menozzi

    Daniele Menozzi - 2009-03-04

    Hi,
    I need to restore a disk image of a 80GB disk on several (hundreds) PCs with bigger disks (250/320/500/ecc).
    The problem is that this disk is a linux disk, with 2 partitions: swap and root. So, if I use the -r option and I try to restore the 80GB image on a 500GB disk, I end up having 2 resized partition, whose size will be 50GB (for swap) and 450GB (for root) - and I do not really want a 50GB swap partition ;)
    So, my problem is that I need to find an automagic way so that I can restore the small image in bigger disks, but having only the root partition to be resized.
    Is this possible? Any clues or ideas?

    Thank you very much!
    Daniele

     
    • Steven Shiau

      Steven Shiau - 2009-03-06

      Daniele,
      I think you have two options:
      1. Prepare the partition table on the target disk first, then turn on "-r" and "-k".
      2. Write a script to create the partition table on target disk, put it in /opt/drbl/share/ocs/prerun/, and check option "-o1".
      Some examples you can refer:
      /opt/drbl/samples/create-*pt-sf

      Steven.

       
      • Steven Shiau

        Steven Shiau - 2009-03-07

        BTW, maybe you can modify /opt/drbl/sbin/ocs-expand-mbr-pt to make it. It's a bash script, so it's not too difficult to modify it.
        If you make it, please share that.
        Thanks.

        Steven.

         

Log in to post a comment.