[Gllug] overwrite superblock with dd

Ben Fitzgerald ben_m_f at yahoo.co.uk
Fri Jan 21 16:56:49 UTC 2005


Hi,

I'm wanting to play with ext filesystemes. I would like to scrub my
first superblock on a partition and then use e2fsck to rebuild it
using a backup superblock from a different block group.

I believe the superblock is 1 block in size. Is this correct?

If the block size is 1024 and the first superblock is the first thing
on the partition, and the partition is /dev/hda4, and I want to use dd:

dd if=/dev/zero bs=1024 count=1 of=/dev/hda4

Should this mean I cannot mount the filesytem on my next attempt?

Or do I need to seek beyond the boot sector (even though this parition
is not marked as bootable? This is 512 bytes, right? If this is true,
the above would still screw 512 of the first superblock.

Thanks in advance for help,

Ben.
-- 
Registered Linux user number 339435
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list