[ltp] Wasted Free Space

George Staikos linux-thinkpad@www.bm-soft.com
Mon, 27 Mar 2000 14:30:48 -0500


-----BEGIN PGP SIGNED MESSAGE-----

On Mon, 27 Mar 2000, Alex Bell wrote:
> Pardon me if this is off topic for this list, but I had no success with
> Usenet.
> 
> Because of mistakes I made when installing Corel Linux on my ThinkPad
> 385XD the computer has a small swap partition and about 23Mb wasted
> free space at the end of the hard drive right next to the swap
> partition.
> 
> Is there any way I can delete the swap partition so as to merge it with
> the free space, and then format the resulting free space as a swap
> partition?  I've looked at linux Fdisk and FIPS but find them hard to
> understand.  
> 
> So far as I know Partition Magic 5 needs Microslop Windows to install,
> and I don't have any Microslop products on my computer.
> 

  Yes.  it's safest to do this kind of thing in single user mode, but if
you're not familiar with this, it still works in multiuser mode (i've done
it many times).  Run swapoff on the swap device, run fdisk and delete the
partition, recreating a new one of the proper size (assuming the swap and the
freespace are adjacent as you said they are).  Toggle it as Linux Swap (type
82 I think?  look it up in the list....).  then take note of the new device
name (ie /dev/hda6 or something like that).  Exit fdisk, saving the changes. 
You _may_ have to reboot at this point.  If you do, just log in as root and
continue (it will tell you if you have to when you exit fdisk - saying
something like "error writing partition").  Now run mkswap /dev/hda?
(whatever hda device your swap partition is).  Then swapon /dev/hda?.  That's
it!  Beware that you can toast your linux installation doing this if you
touch the wrong partition.  Be careful and read all the documentation on the
programs you are using.  I take no responsibility for anything you break. :) 
Playing with partitions is always dangerous.

- -- 

George Staikos 


-----BEGIN PGP SIGNATURE-----
Version: PGP 6.5.2

iQEVAwUBON+46PaardfOEhQRAQHDUgf/Uz7Sm/0RoK+3otFQUHeQ+WD8yi+PCRp6
tf+JNhmWtY12U5NTJQn+nwh+cfxPNtK5ahC9YTkt0upMhF0ze8F5YkV4pAVWfRXr
fhfSkfzhNDmPM8M/pjiabOrUuiRsGAI68PJc0syvlDkJQ0Byrbk/hyGC8rNGH4Kd
76OEFer7UpDYuaj7ay/nNCbcILKkOeioZDzxklA6X7E8JyeJV4KpHCmkMeFibJkf
VMs59ZewIY0v3opIsx+Fm3NlohGM/BOHXGsgdu1J91xBwOFcNgfZhl237jM7BvrO
65ZHkXJw8DD4He4idHWcT5qp7FsRyw/WLVX1X7w68y+QSFr9Yk4kRA==
=ot34
-----END PGP SIGNATURE-----
----- The Linux ThinkPad mailing list -----
The linux-thinkpad mailing list home page is at:
http://www.bm-soft.com/~bm/tp_mailing.html