LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 07-14-2007, 10:20 AM   #1
eyeguytx
LQ Newbie
 
Registered: Jul 2007
Posts: 3

Rep: Reputation: 0
hard drive partitioning - newbie


Building a new machine, installing 7.04 with partitioning problem.

Totally fresh machine components, new 500gb hard drive. Put in ubuntu 7.04 disk, going through setup process. Was reading an online guide and setup the root drive 9gb, then the swap partition 3gb (went by 1.5x memory suggestion on the guide). Ok then there is like approximately 490gb listed under free space left. So I try to partion this as /home for remaining files storage. I put the full amount of space left as that partition and select ok. It only puts like 58gb on the home drive and leaves the rest as a bunch of free space still. Is there a reason or some trick why I can't make a bigger partition?

I'm a linux newbie, not a computer expert, actually I'm an optometrist, so be gentle. ha.
 
Old 07-14-2007, 10:35 AM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
The maximum size of a partition is related to the number of inodes and the cluster/block size of the file system. If you increase the number of inodes then they take up more space on the partition. If you increase the size of the clusters/blocks then every file wastes more disk space. It's a compromise. Generally you want a file system with a lot of small files to reside on a partition with a small cluster/block size so that each file wastes less space. You would want a file system with a lot of large files to reside on a file system with a large cluster/block size in order to allow a larger partition.

And, just to set the record straight about swap space, this idea that the swap space should be 1.5 times the size of RAM is something that a lot of system administrators believe but they are wrong. This rule means that the relationship between swap space and RAM is directly proportional. In other words the more RAM you have the more swap space you have. This also means that if you have very little RAM then you will have a very small swap space. Exactly the opposite if required. If you have very little RAM then you need more swap space. That is because the RAM does not support many processes staying in memory so the operating system has a greater need to swap them out than if you had a lot of RAM.

So a lot of RAM requires less swap space for a given system load while very little RAM requires a large swap space for the same system load. This is the opposite of that rule.

If you have 1.5 GB of RAM then your system will probably not need very much swap space. Some memory hog applications like photo editors and video editors might use all of the RAM and swap space that you have but if you just use office type applications then you will never use 3 GB of swap space.

Last edited by stress_junkie; 07-14-2007 at 10:44 AM.
 
Old 07-14-2007, 10:47 AM   #3
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
I think that you will need at least 1x ram for suspend to disk to work reliably. With today's large hard drives, you wouldn't really miss the extra 500MB.

What filesystem was being selected for the /home partition?

Last edited by jschiwal; 07-14-2007 at 10:49 AM.
 
Old 07-14-2007, 11:26 AM   #4
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Quote:
Originally Posted by jschiwal
I think that you will need at least 1x ram for suspend to disk to work reliably. With today's large hard drives, you wouldn't really miss the extra 500MB.
I hadn't thought of suspend to disk because I never use it. Looks like you got me ... for that configuration.
 
Old 07-14-2007, 11:48 AM   #5
eyeguytx
LQ Newbie
 
Registered: Jul 2007
Posts: 3

Original Poster
Rep: Reputation: 0
file system I tried first was ext3 and then read that xfs was better for big files on the main partition. Both ran into the above problem though of not being able to use all the free space left for the one big partition. Maybe I should just do the non manual install.

One thing is, I didn't really even run the installation disk that came with the new hard drive. I just plugged it in with all the other new stuff and it was recognized on the boot up. Maybe there's some tweaks in that disk?

I have 2gb memory so I had allocated 3gb to the swap, going with the 1.5x theory, but after reading the comments, I guess I'll rethink that since its a home computer and I don't use a lot of high powered applications.
 
Old 07-14-2007, 03:55 PM   #6
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
You can do whatever installation type that you want if you just don't configure the big partition. You can always set up the big partition after the operating system is running. That's what I always do but that's because I encrypt the data partitions with True Crypt.

Once you have the operating system installed you can log on as root and open a terminal window. Read the man page about the mkfs.ext3 command.
Code:
man mkfs.ext3
The most important parameters for this purpose are the -b and -N. These control the things that I mentioned in my first post. The -b parameter controls how many bytes are in a disk block. You could try formatting the partition using 2048 bytes per block. If that didn't work then you could try using 4096 bytes per block. The -N parameter determines the number of inodes that are created in the file system. inodes are the way that the operating system keeps track of file fragments but it also relates to the total size of the partition. More inodes times the block size means a larger maximum partition size. That is really just like the disk administrator in Windows. The principles are exactly the same.

Here is an example to format /dev/hda3 with the ext3 file system, 4096 bytes per disk block.
Code:
mkfs -t ext3 -b 4096 /dev/hda3

Last edited by stress_junkie; 07-14-2007 at 03:57 PM.
 
Old 07-14-2007, 06:35 PM   #7
eyeguytx
LQ Newbie
 
Registered: Jul 2007
Posts: 3

Original Poster
Rep: Reputation: 0
I went ahead and installed without setting up the big partition at first as suggested. After the install I was able to set up the main partition in one piece. Not sure why it would only let me do smaller pieces in the initial setup. I also scaled the swap back from 3gb to 2gb. Anyway, thanks for the suggestions!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Hard Drive Partitioning for Large Hard Drives Matir Linux - General 2 12-26-2006 06:55 AM
Partitioning a Hard Drive wwnexc Linux - Software 1 01-19-2006 01:02 AM
Partitioning a new hard drive soujrnr Linux - Software 2 12-09-2005 05:08 PM
partitioning hard drive marie-p Linux - Newbie 5 01-14-2005 01:23 PM
partitioning my hard drive stearic Linux - Newbie 1 01-07-2001 11:15 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 10:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration