hd probleme on fedora

Jonathan Berry berryja at gmail.com
Fri Oct 29 05:22:59 UTC 2004


On Fri, 29 Oct 2004 00:30:18 -0400, Kevin J. Cummings
<cummings at kjchome.homeip.net> wrote:
> OK, you've created 1 new partition, 80GB in size.
> Now you have to run mkfs on this partition.  You've created it, but it
> contains no data yet, worse, you're probably reading the *old* 20GB data
> left over from the previous partitioning that you destroy.

If you want two partitions, run fdisk again and enter +40G at the prompt:
> Dernier cylindre ou +taille or +tailleM ou +tailleK (1-158816, default
> 158816):
Then add primary 2 with the defaults.  By the way, there is no need to
reboot between deleting the old partitions and creating the new ones. 
In fact, you can do this without even exiting fdisk.  Just delete the
80 GB partition and create the 2 new 40 GB ones, if that is what you
want now.

> You need to understand that partitioning only draws the lines on the
> disk where the files system will live.  It does not re-write the
> superblocks, directories, or data between those lines.  That is the job
> of mkfs.  (Or in your case, mkfs.ext3 if you want an ext3 file system.)

Yes, this is correct.  Interesting result, I must say; I've never
tried that : ).  The command I use is:
# mke2fs -j /dev/hdb1
to make the file system on the first partition.  Repeat with /dev/hdb2
if you go with two partitions.  This is the same as mkfs.ext3 (ext3 is
ext2 with journalling, the -j option).  Note that this will ERASE the
data that is currently on the disk.  It seems this is what you want,
but just making sure.
I don't know if you could somehow run fsck on the disk with the new
partition table and have it fix the filesystem to take up the new
partition space.  Anyone know if this is theoretically possible, out
of curiosity?

Jonathan




More information about the fedora-list mailing list