Create Partition (Standard partition vs LVM physical volume) in CentOS installation

46,222

As I knew, Linux can only create three kinds of partitions. they are primary, extended, and logical

No, that's wrong. What you're describing here is PC old-style “MBR” partitions. This was the standard partition type on PC-type computers (and some others) since the 1980s but these days it's being replaced by GUID partitions. Logical vs primary partition is a hack due to the limitations of this 1980s system which you can ignore if you don't have to deal with older systems.

Using a standard partition system is essential if you have multiple operating systems installed on the same disk. Otherwise, you don't have to. Furthermore, even with multiple operating systems, you can use a single standard partition for Linux, and use Linux's own partitioning system inside it.

LVM is Linux's native partitioning system. It has many advantages over MBR or GUID partitions, in particular the ability to move or even spread partitions between disks (without unmounting anything), and to resize partitions easily. Use LVM for Linux by preference.

LVM achieves its flexibility by combining several levels of abstraction. A physical storage area, typically a PC-style partition, is a physical volume. The space of one or more physical volume makes up a volume group. In a volume group, you create logical volumes, each containing a filesystem (or a swap volume, etc.).

Share:
46,222

Related videos on Youtube

Joe.wang
Author by

Joe.wang

I am interested in Asp.net and Java technology .Now I am working on a project with windows azure paas and iaas. There are so many web application frameworks and tools to use . Velocity for basic needs, raw JSPs, Struts,Spring MVC ,Stripes Framework,Grails, Groovy,Seam,Tapestry 3, Wicket, Echo, and JSF (to be continue...) The funniest thing I have ever seen is from this document How to ask question The Smart Way? Many project websites link to this document in their sections on how to get help. That's fine, it's the use we intended — but if you are a webmaster creating such a link for your project page, please display prominently near the link notice that we are not a help desk for your project! :))) I would like thanks everybody who helps me ever!

Updated on September 18, 2022

Comments

  • Joe.wang
    Joe.wang over 1 year

    All. Forgive me I not familiar with the Linux. I am trying to install CentOS in the VMWare. As I knew, Linux can only create three kinds of partitions. they are primary, extended, and logical, For MBR, the max numbers of primary and extended partition are 4. and The unlimited numbers of logical partitions can be created under the extended partition. (If I was wrong. Please correct me. Thanks.)

    But As to the CentOS. I got the options like below when creating the partitions. Compare to the concept of primary, extended, and logical, I can't understand Standard partition and LVM physical volume and didn't know what is the difference between them. What does it mean creating an LVM physical volume? Could anyone please tell me more about it ?

    Thanks.

    enter image description here

  • Joe.wang
    Joe.wang almost 8 years
    Thank you telling about the LVM and correct me. I just read some about MBR and GPT. howtogeek.com/193669/…. Does it mean Linux (let's say CentOS) support both MBR and GPT? How can I partition with GPT in CentOS?
  • Joe.wang
    Joe.wang almost 8 years
    And from your answer . Did you mean LVM doesn't belong to both (MBR and GPT)?
  • Gilles 'SO- stop being evil'
    Gilles 'SO- stop being evil' almost 8 years
    @Joe.wang Linux supports both MBR and GPT (and many other more exotic partition types, it's very accommodating). I don't know how to select between MBR and GPT in the CentOS installer. Recent versions of the fdisk utility let you choose, and if your fdisk is too old you might have gdisk for GPT partitions. LVM is a different thing, LVM is a Linux-only partitioning system.
  • Joe.wang
    Joe.wang almost 8 years
    Great explain. Thank you for you kind and generous help.+1