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

How to reclaim space on hard drive not partitioned fully initially?



Long ago, in a galaxy far away, I partitioned my 120GB hard drive. 

I think that I did not allocate all the space to used partitions.

i mounted /boot at /dev/hda1
	  /     at /dev/hda2
	  /home at /dev/hda3
swap at /dev/hda5.

me:~# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hda2              19G   16G  1.7G  91% /
tmpfs                 507M  4.0K  507M   1% /dev/shm
/dev/hda1              89M   24M   60M  29% /boot
/dev/hda3              19G   17G  557M  97% /home
tmpfs                 507M  148K  507M   1% /dev


Not that I see only 39GB used here.

Now I am running out of room and I want to use the rest of the space on the 
disk.

fdisk /dev/hda

p

Disk /dev/hda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
   /dev/hda1   *           1          12       96358+  83  Linux
   /dev/hda2              13        2444    19535040   83  Linux
   /dev/hda3            2445        4876    19535040   83  Linux
   /dev/hda4            4877        5119     1951897+   5  Extended
   /dev/hda5            4877        5119     1951866   82  Linux swap

   Command (m for help): n
   No free sectors available

   Command (m for help): ?
   ?: unknown command
   Command action

   Command (m for help): u
   Changing display/entry units to sectors

   Command (m for help): p

   Disk /dev/hda: 120.0 GB, 120034123776 bytes
   255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
   Units = sectors of 1 * 512 = 512 bytes

      Device Boot      Start         End      Blocks   Id  System
      /dev/hda1   *          63      192779       96358+  83  Linux
      /dev/hda2          192780    39262859    19535040   83  Linux
      /dev/hda3        39262860    78332939    19535040   83  Linux
      /dev/hda4        78332940    82236734     1951897+   5  Extended



Why does fdisk find no free space?

When I run qtparted it says

number partition type status size used space start end label
04 /dev/hda4 extended   1.86GB
05 /dev/hda5 linux-swap 1.86GB
06 /dev/hda-1 free    72.57GB     N/A   39.21GB   111.79


It seems I left out alot of space from the logical (extended) partition - how 
do I reclaim it? Also can someone tell me where I can read more about this 
issue?

Mitchell


me:~# cat /etc/fstab
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda2       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda1       /boot           ext3    defaults        0       2
/dev/hda3       /home           ext3    defaults        0       2
/dev/hda5       none            swap    sw              0       0
/dev/hdc        /mnt/hdc   iso9660 ro,user,noauto  0       0
/dev/hdd        /mnt/hdd   iso9660 ro,user,noauto  0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto  0       0
/dev/sda1       /mnt/usb        vfat    rw,users    0 0





Reply to: