sda2 is corrupted

Bryn M. Reeves bmr at redhat.com
Fri Jul 6 14:19:03 UTC 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 07/06/2012 03:11 PM, Jim wrote:
> I run  dd if=/dev/sda2 of=/dev/sdb1  to copy, supposely a 26gb
> image to sdb1 but i do not see a image on  sdb1 .
> 
> Confused ???

That writes a block-for-block image of the content of sda2 to the
device sdb1. It will overwrite any file system, LVM label, swap label
etc. on the device as well as the contents.

If you want to create an image of a device in a file system you need
something like:

dd if=/dev/sda2 of=/tmp/sda2.img

Where /tmp is any path to a mounted file system that you can write to
and that has enough free space for the entire device image. You can
compress these inline if you wish to save space.

Regards,
Bryn.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk/289cACgkQ6YSQoMYUY94oDACfbdOh1MnFXt5/dnUbbrfJ0fW8
U5sAoNnz0hnAHcsWE5E0x5bJ1azNZAc+
=SE7B
-----END PGP SIGNATURE-----


More information about the users mailing list