Is GPT and LVM what I really need?
I just bough a new 2 TB hard disk and I'm wondering, would it be a very wild idea to use GPT instead of MBR? Is there any real advantage? (my BIOS is a regular one, not a UEFI)
And the second part is that I'd like to try some distributions now that I have plenty of space. (I use Ubuntu). Is using LVM a good idea for this? I read that using LVM you can resize your partitions on the fly, and I want to know more about this.
Let's suppose I use the following partitioning method with the old MBR partition table:
Would it be possible to resize sda2 whenever I want (even if it has many GB in use but a few unused) to create other partitions that I'd use with other distributions (Arch, Gentoo, Debian, Ututo)? And if I'm tired of them, give the GBs back to sda2?
Any advice and suggestion is accepted, thank you very much in advance!
Can't say about GPT, all I know is that it's needed for disks larger than 2TB and not all systems supports it.
LVM: This is great, but has some disadvantages.
With LVM and for instance reiserfs you can resize on-the-fly without even unmounting first!
This I have tried several times, always worked - but of course, that is not a guarantee - remember Titanic?.
If you use ext2/3/4 partitions must be unmounted before they are resized, making it a bad combination for your root.
You can also add additional disks as needed, so LVM is really very good.
Downside - and this is taken from real life :-( (ouch what a terrible time I had)
Use LVM, use several disks, create a large partition for movie-files or whatever in that LVM.
Now imaging one disk dies...
I actually managed to rescue everything but it took days.
Without LVM, when one disk or partition goes bad, you have a physical structure to work with. This is far easier than dealing with a logical structure.
Simple solution: take backups to a separate disk. Very often people do what I did: "I'll fix the backup-ing tomorrow"...
So in short: use LVM with a filesystem that allows resizing without unmounting, and configure backups immediately.
Then, IMHO, LVM is the way to go.
And there is no problem sharing LVM:s between distros (NOT Windows though AFAIK) only they must have LVM-support.
Not all have it per default but easily installed.
Hello pingu thank you for helping
First, I'm sorry to hear about your accident, I'm glad you could recover all the data. For the moment I'm not planning to use many different hard disks within a single volume group, or logical volume.
These days I was reading and testing lvm with a virtual machine, and it's a lot of fun! :-D It seems to be exactly what I need. As of GPT, I'm not sure. Would it be of any advantage to use it over MBR in a non-over-2TB hdd? Perhaps somebody could help with this other question.
You say that you can resize your partitions on-the-fly with reiserfs but that problems may arise. Regarding that, can I really resize partitions without running any risks? both file system and the logical volume? (even unmounted, is it safe?). I don't have a good knowledge of how reiserfs works, so I'll be using ext4.
How should I partition my disk? Let's suppose I'm going to use MBR.
Somewhere I read I need to create a /boot partition first, and then I'd give the rest of the space to a lvm partition. Is that a good idea? Can I simply create a single vlm partition and then assign it to a volume group and then create many logical volumes? Bear in mind that I want to boot multiple distributions with the same hard disk.
Did anybody you know try this already? I'm sure a lot of people did! I'd be of great help to hear some of your experiences.
thank you for your help
Ext has handled on-line (mounted) resizing for years. Both enlarging and shrinking.
Whether shrinking a (mounted) root is a good idea at all is debatable - I prefer to do it offline, after having taken a backup. Not a regular event in my case.
LVM is (most) useful in Enterprise environments IMHO. Good for adding storage (pvs), not so for reducing. However it is not a substitute for backups.
As for using multiple distros in the same LVM environment, it should be do-able, but I haven't tried.
The advantage of GPT is that you can use 128 partitions and you can label partitions. The disadvantages are not all OSes
support GPT and to boot you have to use elilo or grub2. For LVM I don't see many advantages so I don't use it.
That could be old though, haven't used LVM since 2010.
|All times are GMT -5. The time now is 03:50 PM.|