Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Welcome to LinuxQuestions.org, a friendly and active Linux Community.

You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!

Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.

If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.

Having a problem logging in? Please visit this page to clear all LQ-related cookies.

Introduction to Linux - A Hands on Guide

This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.

I recently installed redhat el 3 ( only decent CD based distribution I had around) on a Pentium 550 MHz, 326 MB RAM, 8 GB HDD box. It previously had Win2k, which I have chosen to keep, making my system a dual boot.
I have split the HDD into 3 GB for Win2k & 5 GB for Linux, the installation went smoothly, and I have been running both OS's smoothly for over 2 months now.

I followed the thumb rule when creating the swap partition ( twice the RAM size). I also created the shm partition based on the redhat el3 installation guide. Since I am using this mainly as a desktop ( and I am guessing because of the slow speed of the CPU in conjuction with the pretty large RAM size) the RAM is never fully used up ( typically 75% use), the swap space is hardly used ( typically 10% use), and the shm is almost never used. This is even when I am running supposedly memory intensive processes ( like "make -j 8"). I have noticed it is the CPU that is in 100% use ( via gkrellm, everyone should have it on their linux box!) rather than memory.

I am also running very short on disk space, especially under /usr & /home. After that elaborate introduction, heres what this post is for:
I want to increase space by (deleting &/ resizing) /dev/shm & the swap partition. I have looked at other forums, and posting on this one on related topics. My present understanding is
a) It is risky - ( I have made a backup of the entire linux partition using mkCDRec ( everyone should try this app, it _seems_ superb). So not too much worry on that front)
b) The only way is to gain some hd space is to delete the swap partition, make a backup of all the data on the adjacent partition ( before or after, in my case hda8 or hda10), merge with the adjacent partition, reformat the new enlarged partition, migrate the data back. In my case hda8 & hda9 are neither /usr or /home so it still wont help.

Before I ramble on, can some Linux Guru help me do what I want to do, including answering:
0) The whole thing would be fixed if there was something like Partition magic for Linux, a non-destructive re/partitioning/re/sizing tool. Is that correct? Is there one?
1) Can it be done?
2) If yes, please explain in a step by step, explicitly explained manner.
3) What things do I need to be careful of?
4) How much space should I leave under swap & shm given I mostly use it as a desktop box, but plan to run some simple http server ( apache httpd) & maybe subversion server on it.

I did see some other ways I could increase disk space ( like deleting the files under /usr/local/locale? ) & I have done most of them. Any other suggestion would be most welcome.

0) http://www.gnu.org/software/parted/
1) Yes. Although I would be wary of resizing shmfs; it's not a physical disk partition which means that it's held in memory. Memory filesystems tend only to occupy RAM for the used portion of their space, so you may not save much there.
2) See http://www.gnu.org/software/parted/manual/
3) When you are messing with / or /boot, there is a good chance that you might delete your boot-loader. Keep a rescue disk to hand to make sure that you can reinstall it (find out how to do this first).
4) If you never use more than 10% of your swap space, then I'd cut it down to around 20% of its current size.