In <20090603185138.ga25...@m364d1.ece.northwestern.edu>, Zhengquan Zhang wrote: >On Wed, Jun 03, 2009 at 01:46:27PM -0500, Boyd Stephen Smith Jr. wrote: >> In <20090603174408.ga25...@m364d1.ece.northwestern.edu>, Zhengquan Zhang >> >> wrote: >> >Can I say the best practice for lvm is to create a single partition for >> >the harddrive and single PV on it >> >> I prefer not to use a partition table at all if I'm using the whole disk >> for LVM. > >I just read this from the lvm howto > >http://tldp.org/HOWTO/LVM-HOWTO/initdisks.html > >Not Recommended > >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.
This doesn't really apply to me, as I refuse to run MS Windows on my own hardware and haven't had occasion to use BSD/Hurd/Mac OS X/OpenSolaris. >could you explain why it is good to use whole disk for lvm? From what I understand, you might get one extra PE. But, that's all I can think of. There's no performance change. Maybe having a partition table is better, but I don't understand the desire for a partition table when it is not really going to the used to partition (i.e. divide into parts) the disk. >> >and separate LVs for /tmp /var /home >> >> You definitely want separate LVs for any partition (non-system) users >> can write to, to avoid running out of space on your / partition. I >> usually go overboard and have separate partitions for: >> /boot # If / is on LVM; not LV >> /usr >> /usr/local # For OS migrations. > >Could you elaborate on this, I'd really like to learn more about your >setup. Do you put OS independent stuff in this? Right now, the only thing I have in there is /usr/local/share/doc/susv{1,2,3}. It's documentation I want available to any user on the system, but that isn't provided by openSUSE. In the past I also put extra xessions in /usr/local/share/xessions and local scripts or programs in /usr/local/{s,}bin. Basically, it is for replacements/extensions/additions to /usr. I reserve /usr to the OS package manager. This allows be to reformat/delete the contents of /usr -- for migrating from openSUSE to Debian or vice-versa. >> /home >> /opt >> /srv >> /var >> /var/tmp # RAID 0 or other "fast" >> /var/cache # RAID 0 or other "fast" >> /tmp # Usually tmpfs; no LV > >This setup is intense. Yeah, as I said, it might be overkill. For my VPSes I just use the setup my provider gave me; one large partition for / and one small partition for swap. For my laptop, I'm using small partition for /boot, large parititon for LV. LVs for /, /usr/local, /home, and swap. /tmp on tmpfs. My desktop is the only system that has the "full" layout. If you have 2G or more of RAM, you will most likely be fine having /tmp on tmpfs. You can probably do it on even less RAM. -- Boyd Stephen Smith Jr. ,= ,-_-. =. b...@iguanasuicide.net ((_/)o o(\_)) ICQ: 514984 YM/AIM: DaTwinkDaddy `-'(. .)`-' http://iguanasuicide.net/ \_/
signature.asc
Description: This is a digitally signed message part.