Skip to contentSkip to conversation

Are there problems with same VG on same hard disk?

linux-lvm Kai Weber 4 participants 5 messages Apr 9, 2003

lore
Share & tools
lore

Kai Weber

author
#0 lore raw

Hi,

Question: Is it good to have /dev/hdb1 /dev/hdb2 into the same Volume Group? I think I have read that VGs of the same group should not be on the same hard disk. Is this correct or a legend?

Kai

#1 lore raw
Quoted 5 lines

Hi,

Question: Is it good to have /dev/hdb1 /dev/hdb2 into the same Volume Group? I think I have read that VGs of the same group should not be on the same hard disk. Is this correct or a legend?

Why would you want to do that? One of the major benefits with LVM is that you do not have to divide your physical disks into partitions, but to do that through LVM. Also, performance-wise it is not a good idea to do what you suggested.

//Anders

--------
PGP public key: https://tnonline.net/secure/pgp_key.txt

author
#2 lore raw
Quoted 4 lines · Anders Widman

Why would you want to do that? One of the major benefits with LVM is that you do not have to divide your physical disks into partitions, but to do that through LVM. Also, performance-wise it is not a good idea to do what you suggested.

I have removed Windows from a partition. So it is now empty and could be used an included in the VG. If it's possible to resize the partitions...

/dev/hda7          1923      2520   4803403+  8e  Linux LVM
/dev/hda8          2521      3198   5446003+  8e  Linux LVM
/dev/hda9          3199      9729  52460226   8e  Linux LVM

/dev/hda7 is VG system, /dev/hda9 is VG data and /dev/hda8 the new and empty partition. I have no space to backup /dev/hda9 for merging hda8 and hda9. There seems to be no "pvresize" for LVM1.

Kai

#3 lore raw
Quoted 10 lines · Kai Weber
Quoted 4 lines · Anders Widman

Why would you want to do that? One of the major benefits with LVM is that you do not have to divide your physical disks into partitions, but to do that through LVM. Also, performance-wise it is not a good idea to do what you suggested.

I have removed Windows from a partition. So it is now empty and could be used an included in the VG. If it's possible to resize the partitions...

Quoted 8 lines
/dev/hda7          1923      2520   4803403+  8e  Linux LVM
/dev/hda8          2521      3198   5446003+  8e  Linux LVM
/dev/hda9          3199      9729  52460226   8e  Linux LVM

/dev/hda7 is VG system, /dev/hda9 is VG data and /dev/hda8 the new and empty partition. I have no space to backup /dev/hda9 for merging hda8 and hda9. There seems to be no "pvresize" for LVM1.

Sounds perfectly reasonable to me, that's pretty much what I have, though without the shame of previously having windows on the machine :-)

  PV /dev/sda7   VG vg00   lvm1 [20.00 GB / 0    free]
  PV /dev/sda8   VG vg00   lvm1 [9.89 GB / 0    free]
  PV /dev/sdb1   VG vg00   lvm1 [34.18 GB / 3.18 GB free]

...and yes, I swap to an LV too...

patrick

#4 lore raw
In reply to Kai Weber
Quoted 5 lines · Kai Weber

Hi,

Question: Is it good to have /dev/hdb1 /dev/hdb2 into the same Volume Group? I think I have read that VGs of the same group should not be on the same hard disk. Is this correct or a legend?

This is fine. There are a couple of situations that you will have to look out for when setting up LVs though:

1) Don't create a striped LV with the stripes on the same physical device.
2) Try not to create a snapshot on the same physical device as the origin.

Point 2 you can get away with, snapshot performance will just be poor.

- Joe