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

Re: Partition size problem



* haroon <haroonzc@rogers.com> [Apr 27. 2005 07:13]:
> I have following partitions (as shown by cfdisk)
> 
> hda1	ntfs	~20G
> hda2	ext3	~9G
> hda3	swap	~ 1G
> hda4	ext3	~29G
> 
> Total hda size ~60G now if use df to view disk space I get this
> output (I have removed lines that report binded mount points)
> 
> presario:~# df -h
> Filesystem            Size  Used Avail Use% Mounted on
> /dev/hda2             9.0G  7.1G  1.5G  83% /
> /dev/hda4             9.0G  4.7G  3.9G  55% /mnt/data
> /dev/hda1              20G  4.6G   15G  24% /mnt/win
> 
> Now I am confused why size of /dev/hda4 is reported to be
> different?

cfdisk shows the size of the partitions, whereas df shows the
size of the filesystems. It would seem that the filesystem on
hda4 doesn't fill the entire partition. Something like

 # umount /mnt/data
 # resize2fs /dev/hda4
 # mount /dev/hda4 /mnt/data

should fix this. resize2fs will automatically resize to the
size of the partition if no size option is given.
I'm not sure whether resize2fs can resize mounted filesystems. It
couldn't last time I used it, but that is some years ago.

Frederik



Reply to: