Operating System - Linux
1756815 Members
2984 Online
108853 Solutions
New Discussion юеВ

Do I need to Partition a Disk that will be fully used Anyway?

 
SOLVED
Go to solution
Alzhy
Honored Contributor

Do I need to Partition a Disk that will be fully used Anyway?

If I have a disk /dev/sdc and I wanna use it under LVM? DO I need to carve it up say to have a 1 partition -- /dev/sdc1 even if I intend to use the entire disk?

Will having no parition table be a bad thing?

Similarly -- if I use disks under Oracle ASM -- is there really a need to partition the disks?
Hakuna Matata.
4 REPLIES 4
Matti_Kurkela
Honored Contributor
Solution

Re: Do I need to Partition a Disk that will be fully used Anyway?

You don't *need* to do it. If an entire disk has been pvcreate'd, Linux LVM will detect it just fine. I understand Oracle ASM can do that too.

That said, a disk that has been pvcreate'd as a whole disk or given to ASM will look like an unformatted disk to, for example, a Windows installation program.

If there is a chance that your disks might be visible to a Windows system (e.g. a big centralized SAN storage), it might be prudent to create the partition table: it will allow non-Linux systems to detect that the disk is in use, in case your disks are ever accidentally presented to them.

Traditionally, a partition must begin at the beginning of a cylinder. Modern disks don't really have a simple C/H/S geometry any more, but when you create a partition table, the entire first cylinder is dedicated to MBR. So when you omit the partition table, a little less disk space is wasted... but if you have a 160 GB disk, do you care about 80 MB or so?

MK
MK
Ivan Ferreira
Honored Contributor

Re: Do I need to Partition a Disk that will be fully used Anyway?

Using the whole disk as a PV (as opposed to a partition spanning the whole disk) is not recommended because of the management issues it can create. Any other OS that looks at the disk will not recognize the LVM metadata and display the disk as being free, so it is likely it will be overwritten. LVM itself will work fine with whole disk PVs.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Alzhy
Honored Contributor

Re: Do I need to Partition a Disk that will be fully used Anyway?

Thanks Ivan and Matt.

On my vMware cirtualized Linux server - I notice that I cannot forcefully pvcreate a whole vMware virtual disk. It only allows me to pvcreate if I partition it.

However on my Physical Linux Servers where my disks are SAN based and multipathed -- /dev/dm-NN -- I can. I wonder why.

Hakuna Matata.
Steven E. Protter
Exalted Contributor

Re: Do I need to Partition a Disk that will be fully used Anyway?

Shalom,

For the OS partition, yes you need to partition.

Smart partitioning makes it harder for a single problem to fill up the root file system and halt the system.

For an ASM disk, that is not booting the system, it makes no difference at all. Oracle wants to rule this universe and if you have to use ASM your DBA's will be managing space on that disk.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com