Newbie - Need Help adding Free Space to Linux Partition

Newbie - Need Help adding Free Space to Linux Partition

Post by James » Sun, 31 Dec 1899 09:00:00



When I first installed Linux, I set aside 500 mb to eventually install
Windows.  Now I have decided not to install Windows and just run
Linux. How do I add the 500 mb of free space to my Linux partition?  I
am running Red Hat 6.2 in the Gnome X Windows environment.

Any help greatly appreciated.

Thanks,
James

 
 
 

Newbie - Need Help adding Free Space to Linux Partition

Post by Marc Andre Seli » Sun, 31 Dec 1899 09:00:00



> When I first installed Linux, I set aside 500 mb to eventually install
> Windows.  Now I have decided not to install Windows and just run
> Linux. How do I add the 500 mb of free space to my Linux partition?

Unless you want to reinstall, there is no way to add this space
directly to your existing Linux partition.

However, you can make it a separate partition and mount it.  Put one
of the directories that take a lot of space into it, e.g. /var or
/home.  `du -ks' can help you decide which hierarchy to move to the
new partition.

Example: Let us assume this free space is organized as partition
/dev/hda3, and you decide to put your /var directory on it.  Then
you should do something like this:

1) Switch to single user mode or reboot your system in single user
   mode, to ensure no processes are writing to /var while you are
   copying it.

2) Create a file system on the new partition and mount it in a
   temporary place.  Warning: This will erase all data on that
   partition!

        # mke2fs /dev/hda3
        # mount /dev/hda3 /mnt

3) Copy the directory over to the new partition:

        # cd /var
        # tar cf - . | (cd /mnt && tar xpf -)

   This command is a bit complicated: It packs /var into a tar
   archive, which is not actually written to the disk but instead
   passed to another tar which unpacks it under /mnt.

4) Tell your system about the new partition:

        # echo "/dev/hda3 /var ext2 defaults 1 2" >>/etc/fstab

5) Reboot and make sure everything is running flawlessly.

6) Reboot to single user mode again and delete the old /var hierarchy.
   Create some directories that may be necessary if you should ever
   need to boot without the new /var partition.

        # umount /var
        # rm -rf /var/*
        # mkdir /var/lock /var/log /var/run /var/spool
        # ln -s /tmp /var/tmp

 
 
 

1. linux partition ran out of space, can I add FAT32 partition space to / ?

hi,
my linux partition recently ran out of space, i am wondering if i could make
on of my fat32 partition to be use as /, or /usr??
one other question, I have win98 and linux on my system, is there possibility
that linux would kill my extended FAT32 parition??  cuz when i got home, my
brother shutdown my linux and went into win98, then when i went back to linux,
my extend fat32 partition is gone.......all my back up!!
If this question has already been asked, can u just point me to the
information?  thank you

Kuma

my HD(17 gb) info as follow:
hda1  <-- FAT32 Primary partition (4gb)
hda2  <-- ex2 linux partition (1.1 gb)
hda3 <-- linux swap
hda4 <--FAT32 extend partition
   |
    > hda5   these two are partition got lost.........which i dont even know
    > hda6    how......

2. ksh standard in help?

3. Wipe out DOS partition and add the free space to Linux

4. Context switching to Idle - does it?

5. Need to partition remaining free disk space after installed Linux

6. Deskjet 660c

7. hi, how to add free space(not partioned) to root partition?

8. domainname = none

9. Adding free space to a partition?!?

10. Join free space to end of linux partition?

11. linux newbie needs help adding i740 support for xfree86