How To: Partition your Hard Drive.

Write tutorials here
There are more tutorials here http://community.linuxmint.com/tutorial/welcome
Forum rules
Please don't add support questions to tutorials,start your own thread in the appropriate sub-forum instead. Before you post please read this
User avatar
clem
Level 15
Level 15
Posts: 5651
Joined: Wed Nov 15, 2006 8:34 am
Contact:

Postby clem » Mon Feb 05, 2007 11:32 am

Just a quick off-topic question Marcus. In your avatar: is that "tower" in Sydney or Seattle? It reminds me of something I've seen down under.. not to sure though.

Clem
you know those moments when you know you're about to say something obviously stupid ? I feel like that right now.. come on guys finish me :)

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Mon Feb 05, 2007 11:48 am

It's the Seattle "Space Needle", built for the Seattle World's Fair in 1962.

It's actually only this big!
Image
I'm sure Marcus will confirm this.

User avatar
clem
Level 15
Level 15
Posts: 5651
Joined: Wed Nov 15, 2006 8:34 am
Contact:

Postby clem » Mon Feb 05, 2007 11:54 am

ah.. here's the one I was thinking about: http://en.wikipedia.org/wiki/Sydney_Tower

Clem

User avatar
scorp123
Level 8
Level 8
Posts: 2264
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby scorp123 » Mon Feb 05, 2007 12:58 pm

marcus0263 wrote: I've been using Reiser for a few years and have never had a problem, it's pretty stable.
You were just lucky :wink:

marcus0263 wrote: SuSE uses it along with a few other distro's as their default FS.
I always change it to ext3 or XFS. It was exactly on one of my SUSE servers where I once had a really bad crash. I never quite understood why it happened, it just came out of the blue. That day I lost 500 GB of data. Thank you Hans Reiser ... :evil: And besides: Novell/SUSE have dropped ReiserFS as their default filesystem! If you check their wikis and mailing lists they even advise against using it because of the increasing amount of strange stories where people like me lost gigabytes of data due to ReiserFS doing strange things ...

Thank the Gods I had a backup somewhere that day ... But for me ReiserFS is dead. I've heard other horror stories from other admin colleagues who had a similar bad experience. It appears that if your machine goes beyond a certain workload (as it could happen on a server!!) ReiserFS has the tendency to cripple its filesytems all of sudden. You get I/O read errors, you reboot, hoping that a fsck will fix the problem .... and BLAMMMO! your data is gone.

No thanks. If I wanted to lose data without apparent reason I'd be using Windoze. :wink:

User avatar
marcus0263
Level 4
Level 4
Posts: 361
Joined: Mon Dec 25, 2006 9:40 am
Location: Seattle

Postby marcus0263 » Mon Feb 05, 2007 1:20 pm

clem wrote:Just a quick off-topic question Marcus. In your avatar: is that "tower" in Sydney or Seattle? It reminds me of something I've seen down under.. not to sure though.

Clem
you know those moments when you know you're about to say something obviously stupid ? I feel like that right now.. come on guys finish me :)
That's here in Seattle, actually I took the picture from my Apartment. I have to brag I've got a killer view of the Needle, Puget Sound, Mt. Rainer and the Olympic Mountains. No I'm not rich, I just got very lucky with this Apartment :D

User avatar
marcus0263
Level 4
Level 4
Posts: 361
Joined: Mon Dec 25, 2006 9:40 am
Location: Seattle

Postby marcus0263 » Mon Feb 05, 2007 1:45 pm

scorp123 wrote:
marcus0263 wrote: I've been using Reiser for a few years and have never had a problem, it's pretty stable.
You were just lucky :wink:

marcus0263 wrote: SuSE uses it along with a few other distro's as their default FS.
I always change it to ext3 or XFS. It was exactly on one of my SUSE servers where I once had a really bad crash. I never quite understood why it happened, it just came out of the blue. That day I lost 500 GB of data. Thank you Hans Reiser ... :evil: And besides: Novell/SUSE have dropped ReiserFS as their default filesystem! If you check their wikis and mailing lists they even advise against using it because of the increasing amount of strange stories where people like me lost gigabytes of data due to ReiserFS doing strange things ...

Thank the Gods I had a backup somewhere that day ... But for me ReiserFS is dead. I've heard other horror stories from other admin colleagues who had a similar bad experience. It appears that if your machine goes beyond a certain workload (as it could happen on a server!!) ReiserFS has the tendency to cripple its filesytems all of sudden. You get I/O read errors, you reboot, hoping that a fsck will fix the problem .... and BLAMMMO! your data is gone.

No thanks. If I wanted to lose data without apparent reason I'd be using Windoze. :wink:
So far no problems, but if I was to go with another FS I'd use XFS.

But I've everything backed up to where all that I'd need to do is slice up the drives, extract the tarball then install grub. Simple recovery if needed.

But for server, I'd use XFS or what ever fit the bill.

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Mon Feb 05, 2007 2:39 pm

Scorp wrote:
/dev/hda1 -- 15 GB openSUSE 10.2, containing everything but /home
/dev/hda2 -- 15 GB Fedora Core 6, containing everything but /home
/dev/hda3 -- 15 GB Linux Mint, containing everything but /home
/dev/hda4 -- extended partition, from here to the end of the HD
/dev/hda5 -- ca. 75-78 GB shared /home between all three distros (user names could nontheless be different between the three; having the same user name on all three may create new problems eg. with incompatible settings in GNOME and KDE ... with the help of symbolic links stuff like documents, browser settings, etc. could still be shared easily between all three distros and user accounts!) ...Very important: Make sure you only format this partition the first time (e.g. during the installation of the first Linux distro you want to use) and then don't format it in all subsequent installations! Wink Or else: bye bye oh beloved files, bye bye browser settings, bye bye e-mails ... Wink
/dev/hda9 -- swap, whatever is left of the harddisk (e.g. 2 GB)


Following the above scheme, I used GParted to delete existing partitions, add and resize. I could not change the name of the existing extended partition, which is /dev/hda2. Does it matter? If so, how does one change partition names?

I wound up with:
/dev/hda1 -- 15 GB
/dev/hda3 -- 15 GB
/dev/hda4 -- 18 GB
/dev/hda2 -- extended partition, from here to the end of the HD
/dev/hda6 -- 62 GB shared /home
/dev/hda5 -- 2 GB swap

User avatar
scorp123
Level 8
Level 8
Posts: 2264
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby scorp123 » Mon Feb 05, 2007 3:24 pm

kenetics wrote:Following the above scheme, I used GParted to delete existing partitions
It would be better if you deleted everything (if this is possible) and started from scratch. Having your partition numbers messed up could create problems later on. Maybe not tomorrow, maybe not next week, maybe not even next year. But one day it could. All it takes is a broken installer (e.g. the one from a Linux distro that you will want to try out in two years??) that messes up about the partition numberings or their order on the disk ... :wink: Been there, seen it happen :?

So it would be better to have everything tidy and in the right order. 8)

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Mon Feb 05, 2007 9:34 pm

I managed to redo my partitions and got them in proper order. I mounted Mint / on: /dev/hda1 but the install program wouldn't let me leave /hda2 & /hda3 unmounted, So I mounted /usr & /var on them. Now, there's data in those partitions (I guess its done automatically) and I can't install other distros without messing up Mint. I guess I can uninstall Mint but I would be left with the same problem on a re-install. Can that data be moved to the root partition? Thanks again,

Ken

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Tue Feb 06, 2007 9:33 am

I think I'll just delete /dev/hda1,2 & 3 and recreate hda1, reinstall Mint on hda1 and partition hda2 & 3 as needed. That should not interfere with the other partitions numbering. Does that sound logical?

User avatar
marcus0263
Level 4
Level 4
Posts: 361
Joined: Mon Dec 25, 2006 9:40 am
Location: Seattle

Postby marcus0263 » Tue Feb 06, 2007 9:38 am

kenetics wrote:I think I'll just delete /dev/hda1,2 & 3 and recreate hda1, reinstall Mint on hda1 and partition hda2 & 3 as needed. That should not interfere with the other partitions numbering. Does that sound logical?
Best advice is to have at least the minimum number of file systems of

/boot
/
/home

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Tue Feb 06, 2007 10:11 am

What puzzles me is that when I installed Bea, I let it automatically partition the drive and it left me some partitions unmounted. But when I create the partitions manually, it wont let me install Mint and leave unmounted partitions. Just doesn't make sense to me, but then a lot of things don't! :o

User avatar
marcus0263
Level 4
Level 4
Posts: 361
Joined: Mon Dec 25, 2006 9:40 am
Location: Seattle

Postby marcus0263 » Tue Feb 06, 2007 10:19 am

kenetics wrote:What puzzles me is that when I installed Bea, I let it automatically partition the drive and it left me some partitions unmounted. But when I create the partitions manually, it wont let me install Mint and leave unmounted partitions. Just doesn't make sense to me, but then a lot of things don't! :o
Interesting, I don't think I've seen that. I've never had an issue with unmounted file systems.

BTW I never do the "automatic", it's usually pretty ugly.

User avatar
scorp123
Level 8
Level 8
Posts: 2264
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby scorp123 » Tue Feb 06, 2007 5:50 pm

marcus0263 wrote:BTW I never do the "automatic", it's usually pretty ugly.
Oh yes. Better to do it manually ...

crusti
Level 1
Level 1
Posts: 23
Joined: Mon Feb 12, 2007 4:51 am

Postby crusti » Thu Feb 15, 2007 7:57 pm

Kenetics,

Regarding the issue of trying to leave partitions unmounted:

In gParted right after you finalize your actual partitions, you go to the next step to decide which partition is mounted at which mount point and check off which should be re-formatted (make sure you have a file system on the partitions at this point, otherwise you'll get an error). Here's the trick: In order to get Mint to ignore a partition, you have to delete the proposed mount point and blank out the partition entry. (It's annoying because I have so many partitions.)

hda has 3 partitions:
hda1 / for my main Debian OS
hda2 swap
hda3 /home
We now know this is not the recommended setup.

hdb has 10 partitions:
hdb1 / for another Debian
hdb2 swap for Debian
hdb3 /home
hdb5 / for openSUSE 10.2
hdb6 / for Ubuntu 6.10
hdb7 / for Linux Mint Bea
hdb8 swap for 5, 6, 7, 9, 10
hdb9 / for Linux Mint Bianca
hdb10 currently empty

hdc has 1 partition:
hdc1 /woc 160GB of Wide Open Country

So when I installed Bianca, I had to delete lots of suggested mount points.
I distilled my list to just this:
/dev/hdb9 /
/dev/hdb8 swap
/dev/hdb3 /home

All of the remaining entries were deleted so Bianca would ignore them and wouldn't tell me I had unmounted partitions.

This topic leads right into a suggestion about newbie mounting schemes: How easy is it for an installer to accept a SINGLE partition rather than a single hard drive as the chosen install location, and then the installer re-partitions this single partition into scorp123's recommended scheme of /boot, /, /usr, [/opt,] [/srv,] /var, /home. Newbies don't necessarily want to know about how linux should be organized when they're just getting started, but they also may not have an entire hard drive to devote to linux.

Cheers,
crusti

User avatar
marcus0263
Level 4
Level 4
Posts: 361
Joined: Mon Dec 25, 2006 9:40 am
Location: Seattle

Postby marcus0263 » Thu Feb 15, 2007 9:48 pm

At the bare minimum you always want

/boot (I usually got with about 128 Meg, more than sufficient)
/ (10-12 Gig is fine)
/home (the rest)

Also for security reasons in fstab I also have /boot with "noauto", you should only have /boot mounted in a running system if you're upgrading or building a new kernel.

I myself have /var on it's own slice also, but for n00b's the above is good to go till they get more of a feel for Linux.

User avatar
kenetics
Level 5
Level 5
Posts: 628
Joined: Thu Dec 14, 2006 9:57 pm
Location: Somewhere on a Florida beach
Contact:

Postby kenetics » Thu Feb 15, 2007 11:08 pm

Hey crusti, thanks for the information. I will give it a try when I install the Bianca final version.

I've learned a lot about partitioning the last week or two, with some help from the posters here, especially Scorp and marcus. So a big thanks for all your help!

mintero
Level 2
Level 2
Posts: 60
Joined: Fri Feb 16, 2007 2:22 pm

Postby mintero » Sun Feb 18, 2007 8:12 am

That' s my partionning scheme:

hda1 partition for testing distros
hda2 / (mint)
hda3 swap
hda4 /home/<user>/storage with options: nodev, noexec,nosuid

In the storage partition there are the folders of multimedia, system backups, Archives and generally anything that doesnt need backup

Every evening the program sbackup backups automatically /home and /etc in the storage partition.

I know that more partitions means more security, but I love simplicity. Do you think it is a secure scheme? What could be a possible danger?
I dont talk about dangers which could happen 1/ 1000 and could be fixed by reinstalling the system, but about real dangers that is lost or modification of data, manipulation by hackers etc
Any comment is welcome :)
LinuxMint Bea

User avatar
Lolo Uila
Level 5
Level 5
Posts: 576
Joined: Thu Mar 15, 2007 3:40 am
Location: Kapolei, Hawaii

Postby Lolo Uila » Sat May 26, 2007 4:08 pm

What about /tmp? I'm trying to learn about Linux partitioning and besides the /usr and /var partitions I've seen a few articles suggesting /tmp should be on it's own as well (since it gets written to alot).

And if you are going to experiment with different distros, how does that affect a system with /usr & /var on sepparate partitions? Do those also get shared between distros (like /home), or would you need a set of those for each distro?

Thanks. I'm getting ready to deploy Mint on one of my main computers and I'd like to do it "right" so I don't have to redo anything later.

Aloha, Tim

User avatar
scorp123
Level 8
Level 8
Posts: 2264
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby scorp123 » Sat May 26, 2007 5:02 pm

Lolo Uila wrote: What about /tmp? I'm trying to learn about Linux partitioning and besides the /usr and /var partitions I've seen a few articles suggesting /tmp should be on it's own as well (since it gets written to alot).
Yes, I did that once on a server that really got heavy traffic.

Lolo Uila wrote: And if you are going to experiment with different distros, how does that affect a system with /usr & /var on sepparate partitions? Do those also get shared between distros (like /home), or would you need a set of those for each distro?
You can't share those partitions ... they would get into each others way pretty soon. What can be done though is to share e.g. /opt or mount points containing e.g. your web site or other stuff that the package management of each distro won't care about.

If you want to have multiple distros on the same computer you have these options:

- put each distro into it's own partition
- put each distro into it's own partition, but share /home between them
- create an elaborate UNIX-style partitioning scheme for one distro (e.g. the one you expect to use the most or the one you want to expose to heavy workloads ...), place the others into their own single partition, share /home between them

- use multiple large harddisks and create elaborate partitioning schemes for all the distros you want to use. You could probably place 3-4 distros like that on 2-3 very large harddisks ... and still add more distros which you place into single partitions.

A friend of mine had Windows + 8 different Linux distros + some form of BeOS (YellowTab "Zeta OS") on one single machine ... a pretty weird setup!!! :?

:wink:


Return to “Tutorials”

Who is online

Users browsing this forum: greywolf and 5 guests