Hi,
i have been using clonezilla and the nbd/lvm support added for the last 9 months or so
while issue #254 is not always happening i found intermitentley problems with the restore:
1) the old "Unable to find target partition "sda4"" message
or
2) when writing a new image with new files on top of an older image with older content in it the data is actualy not being writen for the lvm and i have old data (since partition sizes and etc etc are all same it actualy works boots but then i notice files in the partition have not been updated
trying again to run clonezilla has resulted in same issue
executing the cleanup commands i sugested and reruning clonezilla has always fixed the issue
export DISK1="/dev/sda" sudo vgremove vg_02 <- it may be vg_01 or whatever vg_xx we are targeting sudo pvremove ${DISK1}7 sudo dd if=/dev/zero of=${DISK1}7 bs=1M count=1 <-- sometimes i zero also the mbr and ebr but not mandatory sudo kpartx -dv ${DISK1} echo -e "d\n1\nd\n2\nd\n3\nd\n4\nw\n" | sudo fdisk ${DISK1} <- deletes all the partitions
i would like to ask if clonezilla is actualy properley cleaning or maybe some command from my sugested cleanup is not being used.
for sure when i et into the bad situation clonezilla cannot clean the old partitions and rectreate them again, but the command above always did the job
i can provide full clonezilla logs if needed
using clonezilla-live-20161010-xenial-i386.iso
just to clarify the comment on this line
- sudo dd if=/dev/zero of=${DISK1}7 bs=1M count=1 <-- this line is mandatory
- the ebr/mbr zeroing i have not found it mandatory but good safe measure "sometimes i zero also the mbr and ebr but not mandatory"
Does this issue exist in the latest stable Clonezilla live 2.5.2-17?
Steven
i tried clonezilla-live-20170626-zesty-i386.iso and the issue is still present
How about Clonezilla live 20170724-artful?
http://clonezilla.org/downloads.php
Steven
are there any code changes between clonezilla-live-20170626-zesty-i386.iso and 20170724-artful , also are all the cleanup commands from above included in this new 20170724-artful image ?
"are there any code changes between clonezilla-live-20170626-zesty-i386.iso and 20170724-artful" -> Yes.
"also are all the cleanup commands from above included in this new 20170724-artful image ?" -> Not really. However, some related changes were done. Therefore please test Clonezilla live >= 20170731-*.
Steven
I'm not sure what is happening, but i create images with same partitions same files just some small changes sometimes in the content of a file.
and the reimaging is not as flowless as it should be.
my asumtion is that since it's same partitions same file system same files (mostley), when all this is being recreated the os is recognizing sometimes new stuff sometimes old.
so for example if we have a hdd and we delete the partition table and then we recreate it teh same , things will work as nothing happened
this makes the old lvm be rediscovered, or some of old files ....
best solution will be before writing the hdd again to zero everything, but that takes time
as good but fast solution besides deleting the lvm, then deleting the partition table, remember the start of mbr and all other partitions and just zero the first 1 mega of each (worked for me this way), this shoudl screw it up well enough that when the partitions and lvm are being recreated old stuff is not automaticaly recognized.
so far due to timelines i just craeted my own cleanup script and ran it with
ocs_prerun="bash /lib/live/mount/medium/live/cleanup.sh"
but i would realy like if clonezilla coudl do a realy good wipe before wirting the image to avoid those issues i encounter when writing same/similar image over and over again on same hdd.
long text but i hope it makes sense.