Menu

Need help setting up a clonezilla restore system

2013-04-25
2013-05-07
  • Brandon Hale

    Brandon Hale - 2013-04-25

    I need to update our system restore setup for a rental company in which we had been using a very old (around 1999) system of using ghost images with an old win98 boot that was scripted to restore the active windows directory from a hidden partition with a stored ghost image on it. Basically they could insert a disk that would boot from win98 straight into ghost, would know where to find the image and restore it, everything automated. They could use the exact same disk on any different computer we have because the restore image was always on the 2nd partition and always had the same name.

    I won't go into detail about why this no longer works, but suffice to say on newer machines that seem to have the advanced format drives on them, mixing a win98 boot partition with a newer active windows boot partition on those drives is impossible. So I need to update it with something that doesn't use over a decade old software.

    I need to create an automated clonezilla restore CD that DOES NOT actually include the image on it, but will completely automate everything from booting up to doing the restore to even restarting the computer after the restore is done. The computers will be set up always having 2 partitions with the 2nd partition containing a clonezilla image of the windows partition that will always be named system.(whatever clonezilla image ext is). We will also keep an image of each different computer's entire drive as well, in case of hard drive failures or otherwise getting hosed by users, which that part I know how to do already. I just need help with creating the automated restore CD, seems like this should easily be done with Clonezilla. My shortcoming is not knowing very much about linux based software so what I have tried before has not worked.

     
  • Brandon Hale

    Brandon Hale - 2013-04-26

    Any ideas on this? I looked through the faq's and nothing is mentioned about this particular method. The automated recovery CD method actually stores the image on the cd, and that isn't what I want.

    I know the command used for what I need it to be is:

    /usr/sbin/ocs-sr -g auto -e1 auto -e2 -c -r -j2 -k -p true restoreparts reload sda1

    Where do I put this? I played with this about a month ago and never could get it to run through. I also need to get rid of both of the "are you sure" hit y to continue confirmations and set it to reboot after done.

     
  • Brandon Hale

    Brandon Hale - 2013-04-26

    Another update on what I've tried:

    following instructions from: http://clonezilla.org/fine-print-live-doc.php?fullmode=0&path=./clonezilla-live/doc/05_Preseed_options_to_do_job_after_booting/01-preseed-options.doc#01-preseed-options.doc

    I've tried using this in my syslinux.cfg (experimenting with the zip before i do an iso):

    label Clonezilla live
    MENU DEFAULT
    # MENU HIDE
    MENU LABEL Clonezilla live (Default settings, VGA 800x600)
    # MENU PASSWD
    kernel /live/vmlinuz
    append initrd=/live/initrd.img boot=live config noswap nolocales edd=on nomodeset noprompt ocs_prerun="mount /dev/sda2 /mnt" ocs_live_run="ocs-sr -g auto -e1 auto -e2 -c -r -j2 -k -p true restoreparts reload sda1" ocs_live_extra_param="" keyboard-layouts=NONE ocs_live_batch="no" locales="en_US.UTF-8"
    TEXT HELP
    * Clonezilla live version: 2.1.1-7-amd64. (C) 2003-2013, NCHC, Taiwan
    * Disclaimer: Clonezilla comes with ABSOLUTELY NO WARRANTY

    When I run that it makes it all the way through, says it's mounting sda2, but then errors out saying no image found in home/partimag. The image is stored in the top level of that partition under a folder I named "reload". Don't understand why it doesn't find that, perhaps something I have incorrect about the mounting process?

     
  • Brandon Hale

    Brandon Hale - 2013-04-26

    The exact error message is "The directory home/partimag/reload for the inputed name does NOT exist"

     

    Last edit: Brandon Hale 2013-04-26
  • Steven Shiau

    Steven Shiau - 2013-04-27

    "The directory home/partimag/reload for the inputed name does NOT exist" -> So are you sure "/home/partimag/reload" exists?

     
  • Brandon Hale

    Brandon Hale - 2013-04-27

    Yep, positive. I created a recovery image on sda2 (2nd partition on the single drive) through saveparts and named it "reload". Double checked it in windows and it's there in the root directory under the folder "reload". I can restore this image as well manually through restoreparts as well. I'm still clueless as to why it can't do this automated.

     
  • Brandon Hale

    Brandon Hale - 2013-04-27

    I guess my problem would lie in the /home/partimag portion of that. I know when I do it manually it mounts that partition as /home/partimag, or at least that's what it tells me, but with the command I'm given it does not. At least not when I preseed "mount /dev/sda2/mnt" only. Any ideas on this Steven? This is where my little understanding of linux and clonezilla kicks in, because I don't understand the significance of /home/partimag.

     
  • Fuchs

    Fuchs - 2013-04-27

    Can you make :
    -open your 'reload' directory in windows OS
    -copy and rename
    'sda-pt.parted.compact' -> 'sda-pt.parted.compact.wri'
    'blkdev.list' -> 'blkdev.list.wri'
    -open these ones [e.g. with wordpad]
    -copy and send us the contents.

     
  • Brandon Hale

    Brandon Hale - 2013-04-27

    blkdev.list.wri:

    KNAME NAME SIZE TYPE FSTYPE MOUNTPOINT MODEL
    sda sda 931.5G disk ST31000524AS
    sda1 |-sda1 894.6G part ntfs
    sda2 `-sda2 37G part ntfs /tmp/local-dev
    sr0 sr0 130M rom iso9660 /live/image DVD+-RW DH-16ACS
    loop0 loop0 99.7M loop squashfs

    sda-pt.parted.compact.wri:

    Model: ATA ST31000524AS (scsi)
    Disk /dev/sda: 1000GB
    Sector size (logical/physical): 512B/512B
    Partition Table: msdos

    Number Start End Size Type File system Flags
    1 1049kB 961GB 961GB primary ntfs boot
    2 961GB 1000GB 39.7GB primary ntfs

    The mount point on sda2 is /tmp/local-dev? Is that what is impacting this process?

     
  • Brandon Hale

    Brandon Hale - 2013-04-28

    Any ideas on this?

     
  • Brandon Hale

    Brandon Hale - 2013-04-29

    So I apparently have remedied this by creating a folder in the root of that partition named "clonezilla" and moved my reload folder into that. Then I included the bind option by adding ocs_prerun1="mount --bind /mnt/clonezilla /home/partimag/" in the preseed options.

    I'm still curious as to why it wouldn't see the reload folder in the root, however, it doesn't really matter at this point.

    All I need to do now is remove all the text output, if possible, that occurs after hitting enter on the initial clonezilla live screen, and remove the 2 "y's" to start the process.

     
  • Fuchs

    Fuchs - 2013-04-29

    It's very fine. You have found any result. Normally it's better to use another repository.
    To remove all the text output remove '-c' in your:

    ocs_live_run="ocs-sr -g auto -e1 auto -e2 [-c] -r -j2 -k -p true restoreparts reload sda1"

    You can see that in the expert mode too:
    [ ]-c Clients waits for confirmation before cloning

     
  • Brandon Hale

    Brandon Hale - 2013-04-29

    Yes, I figured that one out. I posted another question about removing all of the grub loadin that's done between the splash screen and going into the restoreparts if anyone has any ideas on that.

     
  • Fuchs

    Fuchs - 2013-04-30

    The simplest way is to change the time:

    in the
    /EFI/boot/grub.cfg
    set timeout="30" -> "1"

    or in the
    /syslinux/syslinux.cfg
    timeout 300 -> 2

    Or have you an additional grub or grub2 yet ?

     
  • Brandon Hale

    Brandon Hale - 2013-05-01

    To be more specific, I don't want to stop the loading, I just want to stop all the output to the screen between the moment you hit enter on the option you pick for starting clonezilla and before you get to the restoreparts process. To make it even sexier, I wouldn't mind just having a "Please wait while loading...." to be there instead of all the random "loading usb devices" etc. That kind of stuff is helpful to people like us, but unnecessary for the end users I'm making this disk for, if you understand what I mean.

     
  • Steven Shiau

    Steven Shiau - 2013-05-07

    " I just want to stop all the output to the screen between the moment you hit enter on the option you pick for starting clonezilla and before you get to the restoreparts process." -> You can put "quiet" in the boot parameters, this will reduce the output messages. However, it won't be 100% quiet though.

    Steven.

     

Log in to post a comment.