Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Native backup/restore partition options



Scott Ehrlich wrote:
> Please remind me the dd option to preserve just the Linux partitions of 
> the drive? 

Your questions is a little vague as to whether you are trying to 
preserve the partition table or a specific partition.

You do the latter by using the partition device name as the source 
device for dd. So instead of 'dd if=/dev/hda ...' you do 'dd 
if=/dev/hda1 ...' for the first partition.


> I've never played with blocksize, etc.

You shouldn't need to for this, though I typically set the block size to 
something large, like 10 to 100 MB, to maximize throughput when cloning 
disks.


> Also, what is the best way to know where data ends so I know where to 
> start to safely write zeros to the unused area on a partition before 
> preserving it?

The best way is to let the file system figure it out. Just create a 
regular file:

dd if=/dev/zero of=/path/to/partition/zero

Wait until it fails from running out of disk space, and then delete the 
file.

  -Tom

-- 
Tom Metro
Venture Logic, Newton, MA, USA
"Enterprise solutions through open source."
Professional Profile: http://tmetro.venturelogic.com/

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.







BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org