Writing to hard diskForum: HD Install Topic: Writing to hard disk started by: charliep Posted by charliep on April 27 2005,22:16
I have been dabbling with DSL for a few months now so I am really a novice. I am trying to make a CD that includes DSL with a script that will copy disk images and files to restore a hard disk. Things are mostly working, but I want to restore the partition tables and this disk is 40GB with more than 12 partitions. I tried sfdisk from the script, after using it to save the partitions, but unfortunately, the partitions are not nice - the last partition is in the middle (and --force does not work) I decided to use dd to just duplicate the partitions exactly.Example: dd if=/cdrom/part15 of=/dev/hda bs=512 count=1 seek=75012345 After quite a day trying to understand why I could not see the upper partitions, I realised that dd was not working because of the 4 byte limit. I did some internet searches and think I see that dd has a 2 GB limit ! I know that I can use dd to copy the full 40GB disk, but I need to write specific sectors near the end. Is there a dd that "works" or another way to write sectors to the disk that bypasses this apparent limit ? Posted by cbagger01 on April 28 2005,03:44
I have used GNU "dd" to restore partitions that are larger than 2GB.You may need to install the gnu-utils.dsl extension in order to replace the "Busybox" dd that comes with the DSL livecd with "GNU" dd. FYI, the 2GB limit may not be due to the dd command. It may be due to the filesystem that you are using to store your image files. If so, you can use the split command to span your image file over several different files. Here is an example:
and restore:
This will backup to/restore from the hda2 partition to a series of 650MB sized files that are stored at mountpoint /mnt/winshare I have no problems with either a 2GB "dd" limit or a 2GB filesystem limit when I use this approach. And it lets me save my image files to CD-R media. Hope this helps. |