Menu

#77 Restore from lzip fails.

closed-fixed
5
2010-08-11
2010-06-28
Scaz
No

When trying to restore from an lzip image, Clonezilla fails to detect the filetype and bails out with "Unknown format for /home/partimag/path/sda1.ntfs-img.aa!!! Program terminated!"

This seems to be similar to the problem with uncompressed NTFS backups which was fixed (https://sourceforge.net/mailarchive/message.php?msg_name=021101c70949%2487126220%24690aa8c0%40ATGIS05)

The /opt/drbl/sbin/ocs-functions script uses two ways to detect the compression used; filename/extension and the 'file' command. Clonezilla live doesn't save images with the expected extension/filename and I don't think lzip is in the 'file' command based detection. I worked round this by simply copying the 'if' statement from the 'case' statement that detects lzip by filename and putting it after the first detection routine ends.

This occured in clonezilla-live-1.2.5-30-i686.iso and clonezilla-live-1.2.5-17-i686.iso, both Ubuntu and Debian. The target was NTFS (Win XP SP3) cloning a whole disk via parallel lzip.

Other than this glitch, nice program. Really, very nice.

Discussion

  • Steven Shiau

    Steven Shiau - 2010-07-02

    Could you provide a patch file? It's easier for us to modify that.
    Thanks.

    steven.

     
  • Steven Shiau

    Steven Shiau - 2010-07-02
    • assigned_to: nobody --> steven_shiau
     
  • Scaz

    Scaz - 2010-07-05

    Sorry Steven, I'm no programmer. Only know enough to stumble through others' code. Shall have a look and get the line numbers for you at least. As I say, I think it's just that the lzip detection in the second (file command based) routine's been missed out rather than it not working. I'll double check when I've got the chance and update as best I can.

    Thanks.

     
  • Steven Shiau

    Steven Shiau - 2010-07-05

    Or you can email me the file you modified? If so, please email me at <steven _at_ nchc org tw>
    Thanks.

    Steven.

     
  • Anonymous

    Anonymous - 2010-08-06

    Added lzip detection to 'file' metod and works for me, patch based on clonezilla-live-20100729-maverick.

    ####
    *** ./ocs-functions 2010-07-28 12:43:57.000000000 +0200
    --- ./ocs-functions_patched 2010-08-06 21:42:48.607702078 +0200
    ***************
    *** 597,602 ****
    --- 597,607 ----
    cat_prog="lzop -dc"
    zip_stdin_cmd="lzop -c"
    unzip_stdin_cmd="lzop -dc"
    + elif [ -n "$(file -Ls $imgf | grep -i "lzip compressed data")" ]; then
    + # Ex: sda1.ntfs-img.aa: lzip compressed data - version 1, os: Unix
    + cat_prog="plzip -d -c"
    + zip_stdin_cmd="plzip -c $extra_plzip_opt"
    + unzip_stdin_cmd="plzip -d -c"
    elif [ -n "$(file -Ls $imgf | grep -i "PartImage file .* not compressed")" ]; then
    # Ex: hdb1.000: PartImage file version 0.6.1 volume 0 type reiserfs-3.6 device /dev/hdb1, original filename hdb1, not compressed
    cat_prog="cat"
    ###

     
  • Steven Shiau

    Steven Shiau - 2010-08-11

    Thanks for the patch file.
    One thing I do not understand is, by default clonezilla should save the lzip image as:
    -rw------- 1 root root 146M 2010-08-11 20:30 sda1.ext4-ptcl-img.lzip.aa
    The first method in ocs-functions should work...
    Could you please show me your image file content by:
    find /home/partimag/$YOUR_IMAGE/ -print
    (Replace $YOUR_IMAGE with your image dir name).
    Thanks.

    Steven.

     
  • Steven Shiau

    Steven Shiau - 2010-08-11
    • status: open --> closed-fixed
     
  • Steven Shiau

    Steven Shiau - 2010-08-11

    Committed in the CVS repository. It will be included in the next release of Clonezilla live.
    Thanks.

    Steven.

     

Log in to post a comment.