Menu

Scripting help needed

Help
Kazlehoff
2019-07-19
2019-07-22
  • Kazlehoff

    Kazlehoff - 2019-07-19

    Solved! Solution here.

    im trying to script clonezilla live (ram) up to the point where the user only needs to select the image to clone, then select the disk to restore it to.

    this is being done from USB, with the Ram option for clonezilla. USB is one partition.
    the system has two drives and my one USB plugged in
    1: 30GB EMMC storage (mmcblk0p1, mmcblk0p2, mmcblk0p3, mmcblk0p4)
    2: 120GB M.2 SSD (sda1, sda2)
    3: my USB stick (sdb1)

    images are located in the Images folder on the USB's root directory.
    the idea is for the user to select the image from the USB (this allows us to periodically update the images) and then select the mmcblk0 and restore the image onto the EMMC storage, with user interaction as a general failsafe just in case.

    the command im sending clonezilla is as follows:

    linux /live/vmlinuz boot=live union=overlay username=user hostname=artful config quiet components noswap edd=on nomodeset locales=C keyboard-layouts=NONE ocs_prerun="mount /dev/sdb1 /mnt" ocs_prerun1="mount --bind /mnt/Images /home/partimag" ocs_live_run="ocs-sr -g auto -e1 auto -e2 -r -j2 -c -scr -p reboot restoreparts ask_user ask_user" ocs_live_extra_param="" ocs_live_batch="no" vga=788 toram=live,syslinux ip= net.ifnames=0 splash i915.blacklist=yes radeonhd.blacklist=yes nouveau.blacklist=yes vmwgfx.enable_fbdev=1

    it spits back "cant locate images in the /home/partimag directory.

    that directory contains 28 items. see attachment.

    what am i doing wrong here? the ocs_live_run command is the one that was generated when i ran through clonezilla manually. it should work. it must be my mounting thats wrong.

     

    Last edit: Kazlehoff 2019-07-22
  • Steven Shiau

    Steven Shiau - 2019-07-21

    So are you sure /dev/sdb1 is mounted successfully as /mnt?
    What are the oupputs of these commands when you see the error ""cant locate images in the /home/partimag directory"?
    1. sudo df -ah
    2. sudo find /home/partimag -print

    Steven

     
  • Kazlehoff

    Kazlehoff - 2019-07-22

    Solved!

    I was mounting my image directory a directory too deep. instead of ocsprerun1="mount --bind /mnt/Images /home/partimag" i really needed "ocsprerun1="mount --bind /mnt/ /home/partimag""

     

    Last edit: Kazlehoff 2019-07-22

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.