LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   SUSE / openSUSE (https://www.linuxquestions.org/questions/suse-opensuse-60/)
-   -   How have you partitioned your linux system? (https://www.linuxquestions.org/questions/suse-opensuse-60/how-have-you-partitioned-your-linux-system-372951/)

Jongi 10-14-2005 05:44 AM

How have you partitioned your linux system?
 
Mine is one 10GB reiserfs and 1GB swap.

Do others have a seperate /home partition? Seperate /boot? Maybe /var etc?

oneandoneis2 10-14-2005 06:43 AM

Code:

Filesystem            Size  Used Avail Use% Mounted on
/dev/sda6              14G  6.7G  6.5G  51% /
udev                  252M  208K  252M  1% /dev
/dev/sda5              38M  7.0M  30M  20% /boot
/dev/sda7            9.2G  4.5G  4.3G  51% /home
/dev/sda8            7.4G  4.9G  2.1G  71% /usr/portage
/dev/sda9            9.2G  3.5G  5.3G  40% /var/tmp
/dev/sda10            46G  18G  27G  40% /space
none                  252M    0  252M  0% /dev/shm


Quercus ruber 10-14-2005 07:03 AM

Code:

Filesystem            Size  Used Avail Use% Mounted on
/dev/hda5            5.9G  3.3G  2.7G  55% /
/dev/hda7            6.5G  5.1G  1.4G  79% /home
/dev/hda1              25G  8.8G  16G  37% /ntfs
/dev/hdb1            1.2G 1016M  205M  84% /fat-e


Bjerrk 10-14-2005 08:40 AM

I've got a 1 Gb swap, a 29 GB / and a 30 GB /home on my laptop.

On my Server/desktops i've got a 1 GB swap and a 119 GB / and that's it, really.

Kind Regards Bjerrk

Keruskerfuerst 10-14-2005 08:56 AM

Hello!

160GB SATA HDD for Linux:

100MB for /boot
1.5GB for swap
144GB for /

Greetings

mimithebrain 10-14-2005 10:51 AM

I follow these guidelines:
http://mimi.bcdynamic.com/linux/partitioning.txt

normally,
7.5 gig ext3 root
1024 Mb swap
17500 ext3 /home

The rest is for misc OS and experiments.

Gurx 10-14-2005 11:18 AM

A little question: Why 1Gb (or more) for swap ???????

I use only 200Mb for swap (and have 256Mb ram) and don't use more than 5-7% !!!!

I've learn that swap has to be 2x ram, if your ram is less or equal than 128M and 1x or 0.5x ram if you have equal or more than 256Mb ram.

Is this wrong ?

mimithebrain 10-14-2005 11:35 AM

I have 512 mb of ram.

Gurx 10-14-2005 11:38 AM

And how much swap do you really use ?

Keruskerfuerst 10-14-2005 11:54 AM

Hello!

If you use suspend to disk, the swap space has to be >4/3 the size of the ram.

Greetings

Gurx 10-14-2005 11:57 AM

Quote:

Originally posted by Keruskerfürst
Hello!

If you use suspend to disk, the swap space has to >4/3 the size of the ram.

Greetings

Undestand... But I don't use suspend.... Then, in my case I think my swap ammount is correct, isn't ?

Keruskerfuerst 10-14-2005 12:15 PM

Hello!

That depends on, how many programs you are using in parallel (and much ram these programs are consuming).

Greetings

fair_is_fair 10-14-2005 12:23 PM

I have a 160 gig drive.

10 gigs for windows.
50..............ntfs data
20..............fat 32 data
20..............ext2 data
1................swap

5 more partitions for linux operating systems.

mimithebrain 10-14-2005 12:37 PM

Quote:

And how much swap do you really use ?
In mandrake 10.1, very little when I run "stress" or launch 20 konqueror windows at the same time.

danimalz 10-14-2005 03:12 PM

Partition Strategies
 
After many installs, and many re-installs, a few of the dual boot kind, I've got the following recommendations:

I. For a single OS desktop, gui workstation:

1) make / small, perhaps betw. 5-10 (no more) GB.
2) make /home separate for sure, give it 10GB or a little more depending on the size of your disk.
3) make swp 1G

Put these in three primary partitions. use ext3 or reisers for / and /home. Thats all, very simple!

Any additional space on the disk: Leave unused, unpartitioned, and unmounted to begin with.

(if you have a lot of specific data, such as music or video, then add an extended partition at this point and define an appropriate sized partition whithin it. Then mount it as /media or /home/username/media)

Over time as you run your system, it may begin to fill up / or /home above 60% or so. Then it's time to use the flexibility that this scheme offers. Because now you can 'du' your system and find out where the data is actually being used (and what it is).

Perhaps it is /usr, or /var, /home, whatever. Let's say it is /usr because you installed loads of programs. Now you'll create a new partition on the unused space and then just slice off your /usr into the new partition. You'll know from your usage patterns how big to make it. That will clear off your / directory. You can do this ad-infinitum, as needed, with any of the traditional linux 'volumes'.

Let's say you get married and your new wifey or hubby has a load of stuff. Just add them to the system, then cut off another slice of the unused space and mount it as /home/wifey. See! :) The most important thing about creating your system this way is that you have so much flexibility; and you'll never (well perhaps) be in the situation where you have to move or resize / (root), or /boot; you just skim other things off when you need to which is much, much easier. You also become more intimate with your system.


II.

For a dual-boot machine (with windows).

!! Do not let windows do your initial partitioning !!

To partition, install a basic linux system up thru the partitioning point. Partition the disk making sure that the partitions are written, then kill the installation (you can just power off :)). Or use bootable tools, or a live CD.

Make the following partitions (say on an 80gb drive):

Note: *just make everyting, except swap, as ext2 at the outset*

/hda1 -primary- 15GB.
/hda2 -primary- 15GB.
/hda3 -primary- 10GB
/hda4 -swap - 1GB
/hda5 -exetended -rest of space
/hda6 -extended - 20GB
/hda7 -extended - 10GB

Note that there will be approx 10gb remaining in the extended space - leave it alone.

When this is done, run the windows installation, install into the 1st partition reported by windows, verify it by the size. Make sure it is calling it C:/ Doesn't matter that you have made it ext2, windows will immediately create NTFS anyway (dont use 'quick' format).

Once you've booted, tested and updated windows, use the windows system
|control panel-administrative tools-computer management-storage-disk management|
to identify and format two of the remaining partitions, as follows:

/hda2 - ntfs
/hda6 - fat32

Windows doesn't display the partitions as /hda1, /hda2, etc. It will show the windows system partition as "NTFS" and "Healthy (System). The rest should be "Unknown", but they should be in the correct order. You can further identify them by the sizes reported for the 'unknown' partitions.

When you've identified the correct partitions, right click them and do the formats.

When this is done (wait till windows has finished formatting them!!), use windows explorer to find 'My Documents' - right click it, and there will be an option to 'move' this folder. Move it to the NTFS volume that you formatted (might be G:/ drive). Now all of your windows data will be safe, separate, and on NTFS. Trust me, you've just made your future Windows experience much easier.

The fat32 partition you will use for sharing data between the two OS's, as both can read and write to them without screwing each other up. This is where you'll probably want to put music, video, photos, and some other data files (more on this below). The thing is, that partition will be available to either OS, whenever they are booted - cool!


Now install linux, as follows, using ext3 or reisers (except swap):

( be careful!! some distros will offer to automatically partition, or use the entire drive. You must do this manually! - it's not hard)

/hda3 - /
/hda4 - swp
/hda7 /home

Go thru the install. When linux is installed and boots, immediately:

Do a | # fdisk -l | to verify and understand what you've got.
Do a | # mount | to verify and understand what you've got.
Do a | # df -h | to verify and understand what you've got.

Do a | # mkdir /mnt/fat32 |
Do a | # mount -t fat32 /dev/hda6 /mnt/fat32 |

Make sure it's working, that you can mount it and see it.

Do a | # touch /mnt/fat32/newfile |

If all is well, Add /dev/hda6 to fstab, mounted as fat32, something like this:

/dev/hda6 /mnt/fat32 vfat auto,umask=000 0 0

(actual mount-points, of course, are up to you)

!!!! make a linux boot disk right away !!!!

Your're done!. This is what you'll have:

/hda1 15GB. ntfs windows system
/hda2 -15GB ntfs windows user data
/hda3 10GB ext3 linux system
/hda4 -1GB swp linux swap

/hda6 - 20GB fat32 windows/linux share space
/hda7 - 10GB ext3 linux user data

unused - approx 10GB future use, linux or windows, whatever may come up.

Notes:

1. After partitioning, always install windows first.
2. Never do initial partitioning with windows. Never do subsequent partitioning with windows. That's how you get those "partition doesn't end on cylinder boundary" errors.
3. When doing the initial partitioning, do not worry, at all, about the filesystem type or setting bootable flags. Just get your partition sizes right, the way you want them, in advance, and write them down. As you are creating them, check and double check. Then write them. Then check again.
4. Many dual-booters will have experienced MBR failures, etc. Or grub one day doesn't list windows as boot option -I know I have experienced both. If this should ever occur under this scheme - do not panic! Your windows is safe from linux. Worst case is to put in your windows install disk, go to recovery, and run 'fixmbr'. Your linux is safe from windows - you've got a boot disk.
5. Obviously you can adjust the sizes ive given to suit your needs and your availabe GBytes. One tip is to be careful to make the partitions just a little bit different (frome each other) in size so you can be sure which is which when formatting them with windows.
6. Surprisingly, full installations of either windows or linux systems dont take up that much space relative to the large disks now avail (Im writing this circa winXP service pack 2 and Linux 2.6.12 Etch. Really - If you have a 200GB disk, you still only need about 10G (20max) for the linux / or the windows C:/ ** whatever scheme you decide on, don't make the mistake of using the entire drive for the system**
7. Eventually you'll stop using windows so much. Then you can take back the fat32 and 2nd ntfs spaces into your linux system :) But keep the windows - at minimum you'll keep the license you paid for fresh.
8. I learned the hard way about single partition installations of windows. ALWAYS use a separate partition for your data - move that "My Documents" folder right away. This can save your life if (when) the system is mean to you. Also, it is helpful relative to backups, recovery and disk fragmentation. You might also want to set your browser(s) to put temporary internet files onto the fat32 volume; this will help mitigate fragmentation on your ntfs volumes. Very easy to copy data off of fat32, reformat, then put it back for fat32 maintenance. (try that with windows system volume!!) Doing these simple things, you may never need to defragment again.
9. For Linux or windows servers, there are many schools of thought that relate to security, backups, speed, redundancy, swap, memory, production environments etc. If you're installing a server obviously these suggestions are not for you.
10. A little forethought at install of any system pays off huge.

Apologies for any errors in this text. These strategies are based on my experience with using windows and linux, as well as reading. Wise suggestions and criticisims are very much appreciated!!

I use debian, and this works well for me under that distro. I don't know the installation options for very many other distros, and there's a chance that the process decribed above wont work for you.

Hope this has been helpful.


All times are GMT -5. The time now is 10:44 PM.