Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
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.
Click Here to receive this Complete Guide absolutely free.
Hi, Im trying to install redhat 9 to my computer, i have XP installed to my 80gb HD and made a 7 gb partition to install redhat on. when installing it talks about a swap partition, what exactly is that? And if i choose one, which partition do i choose to make my swap partition?
Another question i have is on the partition i am installing redhat on, which mount point do i pick? and which file system do i choose as well?
As a newbie I would delete the 7gb partition and select autopartition during the install. This will create 3 partitions. /boot, / and swap. The default filesystem is ext3.
Swap is the same thing as virtual memory in windows. A method to exchange process and data between RAM and the hard drive when an application requires more memory then available. Windows uses a swap file i.e. pagefile.sys where linux uses a swap partition.
I have windows XP installed as the first partition on my disk (HDA1), I have linux on my second (HDA2) I have a pare biut of fat32 as the third (HDA3) and my forth (HDA4) is linux swap.
Having a swap partiton is a good thing it is like the swap file in windows but more efficient. Mine is 1GB and seems to be a good size for what i do. You can use any partition as a swap partition but make sure it is empty before letting it get formatted!
If you are going for a simple install with one linux partition (and a swap one) you would mount the linux partition (it'll be of type ext2 or ext3) as /
so in summary - make sure you have your 7GB partition for your linux installing AND another smaller partition for swap. Make the 7GB one ext3 (or ext2 (ext3 seems to be the way things are progressing towards)). I seem to remember being advised to have the swap partition twice the size of your memory. And tell the installer to mount your linux partition as /
Easiest way to do it would be to get to the partitioning part in the installer, delete the 7GB partition, and select the auto-partition option. It will then take that now-free-space and create at least two partitions... / and swap. If you want to create them yourself, then you only really need those two partitions. You can make more (/home, /usr, /var), but unless you know what you are doing, you could be wasting space on one partition and running out of it on another. Make your / (root) EXT3, and your swap swap.
If you have a bunch of programs running, and try to open another, you might run out of RAM. The computer than starts swapping stuff out of memory to the swap partition so that it can free some up for the new program. Windows uses that main partition, Linux uses a separate partition. Back when computers had less than 100MB of RAM, the standard suggestion was to have a swap 1.5 times the size of your RAM. Nowadays, if you have more than 256MB or more, and you aren't using huge files, you prob'ly won't touch the swap often. It's still good to have 128MB of swap, just in case.
In addition to the usual /boot, /, and swap partitions I'll make a few other reccomendations for security and performance.
First of all the outer edges of the hard drive perform better than the inner ones. It's not that noticeable but I still get in the habit of placing the swap partition fairly early on in my system. Other partitions you may want to consider mounting parts of the / filesystem on are /home, /tmp, and /var. For the most part these areas are publically writeable and can fill up. If they are on the same partition as your / directory the system will lock up if the partition fills up. This is commonly called a type of Denial of Service attack or DoS attack. If you have the ability here is what I would reccomend for a partition table on an 80 gig hard drive.
hda1 windows 40gb (primary) Your Windows Partition
hda2 /boot 200mb (primary) The Linux boot files
hda3 swap 2gb (primary) Linux Swap File
hda4 extended * (extended) Contains all other partitions and is remainder of drive
hda5 / 20gb (logical) Contains Core System Files
hda6 /home 10gb (logical) Contains user created files and settings (makes it easy to backup)
hda7 /var 4gb (logical) Contains files that change size often.
hda8 /tmp 4gb (logical) Contains temporary files used by programs and users.
This is by no means accurate sizes but is the general idea. The rest of the system you can pretty much leave on one partition. Some people like to put the /usr and/or parts of it on a separate partition but this is often not needed and other directories in root can make the system unstable or worse if mounted away from the / partition.
Once you get more familiar with Linux and with how the system really ticks you may get other idea or prefrences. I usually also add a small 1gb partition that has a minimal install on it to use as a system recovery partition. I load up the OS on the small partiton... point lilo towards it, and never boot it again until I need it to fix the others. It can run my web site, ftp, and mail for me as an internal backuup server while i fix whatever i messed up on my primary install.