I had three partitions on my HDD, however, when I started cloning, Clonezilla was showing 8.
The 4th, 7th and 8th were the partitions I had my data in, the rest were don't know what...
I used the following command: ocs-onthefly -g auto -e1 auto -e2 -j2 -r -rescue -icds -fsck-src-part -k1 -f sdb -s sda
20% through the 7th one, I started getting the error "Warning: Can't read sector at #############, lost data"
This kept on reappearing with different numbers, the rate kept on decreasing until it fell from 5Gbps to 199mb, the time remaing kept on increasing until it reached 6 hours, I checked after 12 hours it said 8 hours remaining. Now the computer had been running for 32 hours.
I thought my source HDD was failing, which is why I added -rescue in the command since it was having many errors in dskchk,so I pressed the power button so it would move on to the 8th partition (this is the recovery partition, not so important), which it did with the rate at 2Gbps and time remaining at 9 mins... When I came back to check after a couple of minutes the PC was off.
I started my PC to check if I could still boot with my old HDD, the system straight up went into Windows recovery mode and was unable to boot telling me "Your PC/Device needs to be repaired Error 0x000025".
I switched the HDD's and tried to boot with my newly cloned HDD but the PC says Smart Hard Disk error 301. I pressed enter to continue, it said the boot configuration data for your PC is missing.
When I ran dskchk on the drive by using HP recovery mode, it says "The type of the file system is RAW".
The funny thing is I just tried to check the source disk by using a SATA to USB converter in another laptop, its working fine and the data in the 7th partition is accessible too.
When I connected the new HDD its saying I need to format before I can use the partitions, although all three partitions are showing up in File Explorer.
What should I do? And what seems to be the problem??
I want to be able to boot from ad use the new HDD as if nothing has change, as I thought Clonezilla will enable me to achieve.
Last edit: Abdul Rafay Khan 2016-03-20
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
It seems the disk cloning did not finish. Which version of Clonezilla live did you use?
BTW, please do a memtest on the machinie to see if your RAM is ok or not.
Steven
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I believe since the clones filesystem is RAW, it's pretty much useless.
I had to use the recovery disk to fix Windows on my source disk, after which it booted fine.
Is it possible to run the cloning process again, however, this time exclude sda7 (the partition with the bad sectors) from the cloning process and clone the rest of the 7 partitions, sda1 to sda8??
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am finding it hard to find any guidelines on restoreparts on the clonezilla website or in the program itself, like even any vague guidelines on what it is or how could I use it...
Any help you can give me or direct me to, to be enable me to understand and use restoreparts...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK, so you are working on partition to partition cloning, not image restoring.
There is no way to exclude some partitions whey you do disk to disk cloning.
However, you can use command line to finish that, i.e.
1. Create the partition table on the destination disk manually by fdisk or some partition table edtor, in your case yoiu have mentioned, it's /dev/sda
(//NOTE// Please make sure /dev/sda is the destination, and /dev/sdb is the source one.)
2. Clone the partition one by one. You can make this as a script file to make it:
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb1 -t sda1
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb2 -t sda2
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb3 -t sda3
...
//NOTE// Backup important data before you use Clonezilla. Just in case.
Steven
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I need to clone sda1 to sdb1, sda2 to sdb2, sda3 to sdb3 and sda4 to sdb4.
Should this be all the text that needs to be in my script:
"#!/bin/bash
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda1 -t sdb1
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda2 -t sdb2
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda3 -t sdb3
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda4 -t sdb4"
I have no idea what I need to do here, please help!!!!
I just need a script, then your website is pretty clear on what do after.
On another note, the problem is the webpage I referred to says "More examples are available in /usr/share/drbl/samples/" but where is this in the bootable USB I made or the ISO I downloaded??
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
'Should this be all the text that needs to be in my script:
"#!/bin/bash
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda1 -t sdb1
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda2 -t sdb2
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda3 -t sdb3
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda4 -t sdb4"' -> Yes.
As for how to write a shell script, you just google and you can find it. E.g. http://linuxcommand.org/lc3_writing_shell_scripts.php
'"More examples are available in /usr/share/drbl/samples/" but where is this in the bootable USB I made or the ISO I downloaded??' -> Just boot Clonezilla live, enter command line prompt, then you can change directory to /usr/share/drbl/samples/, and you can find all of them.
You can find someone there who is familiar with GNU/Linux to help you. It would be easier.
Good luck.
Steven
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I had three partitions on my HDD, however, when I started cloning, Clonezilla was showing 8.
The 4th, 7th and 8th were the partitions I had my data in, the rest were don't know what...
I used the following command:
ocs-onthefly -g auto -e1 auto -e2 -j2 -r -rescue -icds -fsck-src-part -k1 -f sdb -s sda
20% through the 7th one, I started getting the error "Warning: Can't read sector at #############, lost data"
This kept on reappearing with different numbers, the rate kept on decreasing until it fell from 5Gbps to 199mb, the time remaing kept on increasing until it reached 6 hours, I checked after 12 hours it said 8 hours remaining. Now the computer had been running for 32 hours.
I thought my source HDD was failing, which is why I added -rescue in the command since it was having many errors in dskchk,so I pressed the power button so it would move on to the 8th partition (this is the recovery partition, not so important), which it did with the rate at 2Gbps and time remaining at 9 mins... When I came back to check after a couple of minutes the PC was off.
I started my PC to check if I could still boot with my old HDD, the system straight up went into Windows recovery mode and was unable to boot telling me "Your PC/Device needs to be repaired Error 0x000025".
I switched the HDD's and tried to boot with my newly cloned HDD but the PC says Smart Hard Disk error 301. I pressed enter to continue, it said the boot configuration data for your PC is missing.
When I ran dskchk on the drive by using HP recovery mode, it says "The type of the file system is RAW".
The funny thing is I just tried to check the source disk by using a SATA to USB converter in another laptop, its working fine and the data in the 7th partition is accessible too.
When I connected the new HDD its saying I need to format before I can use the partitions, although all three partitions are showing up in File Explorer.
What should I do? And what seems to be the problem??
I want to be able to boot from ad use the new HDD as if nothing has change, as I thought Clonezilla will enable me to achieve.
Last edit: Abdul Rafay Khan 2016-03-20
It seems the disk cloning did not finish. Which version of Clonezilla live did you use?
BTW, please do a memtest on the machinie to see if your RAM is ok or not.
Steven
I did and the memtest results were "OK".
I believe since the clones filesystem is RAW, it's pretty much useless.
I had to use the recovery disk to fix Windows on my source disk, after which it booted fine.
Is it possible to run the cloning process again, however, this time exclude sda7 (the partition with the bad sectors) from the cloning process and clone the rest of the 7 partitions, sda1 to sda8??
You can try to use "restoreparts" in the Clonezilla menu, and select the partitions you want to restore.
Steven
I am finding it hard to find any guidelines on restoreparts on the clonezilla website or in the program itself, like even any vague guidelines on what it is or how could I use it...
Any help you can give me or direct me to, to be enable me to understand and use restoreparts...
Here you can find a complete example:
http://clonezilla.org/show-live-doc-content.php?topic=clonezilla-live/doc/02_Restore_disk_image
and here you can choose "restoreparts":
http://clonezilla.org/clonezilla-live/doc/02_Restore_disk_image/images/ocs-08-restoredisk.png
Actually the step-by-step docs have many info, please read them:
http://clonezilla.org/clonezilla-live-doc.php
Steven
Hold on, I asked you for a way to run the cloning process that would disclude sda7 and include all the rest of the partitions...
However, I believe the restoreparts command that you are suggesting is to restore the clone that I have already made and is "RAW", am I correct?
OK, so you are working on partition to partition cloning, not image restoring.
There is no way to exclude some partitions whey you do disk to disk cloning.
However, you can use command line to finish that, i.e.
1. Create the partition table on the destination disk manually by fdisk or some partition table edtor, in your case yoiu have mentioned, it's /dev/sda
(//NOTE// Please make sure /dev/sda is the destination, and /dev/sdb is the source one.)
2. Clone the partition one by one. You can make this as a script file to make it:
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb1 -t sda1
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb2 -t sda2
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sdb3 -t sda3
...
//NOTE// Backup important data before you use Clonezilla. Just in case.
Steven
Thank you for all your help Steven.
One last problem, I have never written script before. I was able to find a little about it on this forum (like where to save the script file) and here: http://clonezilla.org/advanced/customized-clonezilla-live.php
I need to clone sda1 to sdb1, sda2 to sdb2, sda3 to sdb3 and sda4 to sdb4.
Should this be all the text that needs to be in my script:
"#!/bin/bash
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda1 -t sdb1
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda2 -t sdb2
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda3 -t sdb3
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda4 -t sdb4"
I have no idea what I need to do here, please help!!!!
I just need a script, then your website is pretty clear on what do after.
On another note, the problem is the webpage I referred to says "More examples are available in /usr/share/drbl/samples/" but where is this in the bootable USB I made or the ISO I downloaded??
'Should this be all the text that needs to be in my script:
"#!/bin/bash
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda1 -t sdb1
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda2 -t sdb2
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda3 -t sdb3
/usr/sbin/ocs-onthefly -g auto -e1 auto -e2 -r -j2 -f sda4 -t sdb4"' -> Yes.
As for how to write a shell script, you just google and you can find it. E.g.
http://linuxcommand.org/lc3_writing_shell_scripts.php
'"More examples are available in /usr/share/drbl/samples/" but where is this in the bootable USB I made or the ISO I downloaded??' -> Just boot Clonezilla live, enter command line prompt, then you can change directory to /usr/share/drbl/samples/, and you can find all of them.
You can find someone there who is familiar with GNU/Linux to help you. It would be easier.
Good luck.
Steven
Thank you Steven VERY MUCH for the concise guide And the script...
I'll try and post back here as soon as I am done!