LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Resizing a boot partition to free more space (https://www.linuxquestions.org/questions/linux-hardware-18/resizing-a-boot-partition-to-free-more-space-550726/)

harlikoen 05-02-2007 01:49 PM

Resizing a boot partition to free more space
 
Hey all ;)

I recently reinstalled my Debian distribution due to minor problems. In my rush I forgot to set up a swap-partition! I kept wondering why I had speed problems (it's an old machine with a minimum of RAM).

Anyway, stupid as I was, I partitionized the entire drive for the debian system. Is it somehow possible to resize this? I would like to avoid using a floppy or CD if possible, since the hardware doesn't exist in that box, and I would have to move use the one from my other machine ;)

Can this be done in any way?


Thanks!

b0uncer 05-02-2007 01:55 PM

If you were to resize a partition, that partition can't probably be in use at the moment; that means you'll need to boot from an external media (cd, dvd, floppy, usb stick or whatever is supported) to be able to use some resizing software on the partition to be resized so that the partition is unmounted during the operation. That is, if you only have one partition (you said you "partitionized the entire drive for the debian system"). If you had two partitions, for example, you could probably/hopefully unmount the non-root partition and resize that. Operating on a mounted partition, if some program lets you do that, may result in a lot of damage to the data inside :)

dgar 05-02-2007 02:32 PM

According to Linus, and others, there is no real performance difference anymore between swap-files and swap-partitions.

sudo dd if=/dev/zero of=/.swapfile bs=1M count=2048
sudo mskwap /.swapfile
echo '/.swapfile none swap sw 0 0' | sudo tee -a /etc/fstab
sudo swapon -av

jay73 05-02-2007 02:39 PM

Code:

sudo dd if=/dev/zero of=/.swapfile bs=1M count=2048
Are you recommending using 2GB? Wouldn't that be way too much for an old system with little RAM?

harlikoen 05-06-2007 11:00 AM

Ok so basically, you guys recommend to just set up a swap file instead of a dedicated partition?

:)


All times are GMT -5. The time now is 09:37 AM.