Re: LVM2

2010-06-17 Thread William Immendorf
On Thu, Jun 17, 2010 at 12:31 AM, Glendon Blount itly...@gmail.com wrote:
 I am looking for help installing lfs on logical volumes. The only
 information I could find was from 2009 and used a version of lvm2 that
 is no longer available also the only patch is for this version
 LVM2.2.02.53 I made an attempt to install lfs and got to the kernel
 were I not able to compile the kernel sources. A little background I
 have been using linux since about 1997 and I now use gentoo on all my
 machines I was looking at lfs to install on my hp mini 311 with an
 atom processor I have gentoo booting from an external usb hard drive
 and was hoping to do a lfs installation in the same manner also do I
 need a 2 to 3 g partition for the / directory or a 10 g partition the
 reason I ask is my gentoo / partition is 750 m and my partition layout
 for lfs on lvm would be. I thank you for your time
The LFS partitioning guide should help you out somewhat on how big you
should make your partitions. Other than that, you should look at my
updated hint for LVM as well to get the updated version of the tools
mentioned. Also, to help you out, this is my partitioning setup for
LVM:

/dev/sda1 - /boot - 100 MB (Seperate partition from the LVM setuo, to
keep GRUB from malfunctioning.)
/dev/lfs/swap - swap - 3 GB (I adjust the swap size to match the
amount of RAM in the machine. If I had 4GB or higher, I would defintly
expand this partition.)
/dev/lfs/root - / - 10 GB (If you have a 10 GB partition for root, I'd
defiantly recommend separate partitions for /var and /sources or
/usr/src.)
/dev/lfs/opt - /opt - 10 GB
/dev/lfs/tmp - /tmp - 2 GB
/dev/lfs/var - /var - 40 GB (I defiantly recommend using this
partition, as the last time I've tried a seprate partition setup, my
root partition got full after installing a full KDE4. I'd defintly use
this partition.)
/dev/lfs/sources - /sources - 40 GB (This could be the /usr/src
partition, in my system, /usr/src is a link to /sources.)
/dev/lfs/home - /home - 40 GB (In a regular system, this fills the
remander space, but in a LVM2 system, I'd make it 40 GB to leave some
extra space for growing and snapshoting.)

This partition layout takes up 145 GB of hard drive space (I use a 320
GB hard drive, making 175 GB of free partitioning space to grow
partitions or to take snapshots of them.) Depending on your hard drive
space, you might want to adjust my layout a bit to conserve space.

But, before I go, remember this #1 LVM Rule: Always leave space for
partitions to grow or to make snapshots.

-- 
William Immendorf
The ultimate in free computing.
Messages in plain text, please, no HTML.
GPG key ID: 1697BE98
If it's not signed, it's not from me.

--

Every nonfree program has a lord, a master --
and if you use the program, he is your master.  Richard Stallman
AUTHOR: Bryan Kadzban bryan at linuxfromscratch dot org

DATE: 2010-06-13

LICENSE:
Creative Commons Attribution-Share Alike 3.0 United States
(http://creativecommons.org/licenses/by-sa/3.0/us/)

SYNOPSIS: LFS on RAID, dm-crypt, and/or LVM2

DESCRIPTION:
This hint explains how to build an LFS system capable of booting most RAID, most
dm-crypt, and most LVM2 setups.  It allows you to use dmraid (most RAID add-on
boards), and/or Linux kernel md RAID.  It also allows you to encrypt the RAID
array, and use LVM2 on top of the encryption.  The rootfs can then be a logical
volume.

Any of these transformations can be omitted, but the transformations must be
layered in this order.  It is worth noting explicitly that this hint does not
cover encrypting a single logical volume (encryption after LVM); it only covers
encrypting the entire PV.

PREREQUISITES:
On the host:

- LVM2 userspace tools, if required.
- dmraid, if required.
- mdadm, if required.
- LUKS-capable cryptsetup, if required.
- Also all dependencies of the above packages.

For the LFS system:

Required:

- Sources for LVM2 userspace tools (with device-mapper): at least version
  2.02.53.  Note that all the other packages require device-mapper, so you will
  need the LVM2 package even if you don't plan on using LVM. (NOTE: This 
package is now in BLFS, 
  but the instructions only build the device-mapper part of the package. To 
build the LVM2 parts of the package, use the instructions in this hint.)

  http://sourceware.org/lvm2/
  ftp://sources.redhat.com/pub/lvm2/LVM2.2.02.67.tgz

- Patch for LVM2 udev rules, to make them work better with udev in LFS.

  
http://www.linuxfromscratch.org/patches/downloads/lvm2/LVM2-2.02.67-fix_udev_rules-1.patch

- Sources for lfs-initramfs, newest stable version.

  http://www.linuxfromscratch.org/~bryan/lfs-initramfs-1.0.tar.bz2

Optional (depends on configuration):

- dmraid sources: newest stable version.

  http://people.redhat.com/heinzm/sw/dmraid/src/
  http://people.redhat.com/heinzm/sw/dmraid/src/dmraid-1.0.0.rc16.tar.bz2

- mdadm sources: newest stable version.

  http://neil.brown.name/blog/mdadm
  http://www.kernel.org/pub/linux/utils

LVM2

2010-06-16 Thread Glendon Blount
I am looking for help installing lfs on logical volumes. The only  
information I could find was from 2009 and used a version of lvm2 that  
is no longer available also the only patch is for this version  
LVM2.2.02.53 I made an attempt to install lfs and got to the kernel  
were I not able to compile the kernel sources. A little background I  
have been using linux since about 1997 and I now use gentoo on all my  
machines I was looking at lfs to install on my hp mini 311 with an  
atom processor I have gentoo booting from an external usb hard drive  
and was hoping to do a lfs installation in the same manner also do I  
need a 2 to 3 g partition for the / directory or a 10 g partition the  
reason I ask is my gentoo / partition is 750 m and my partition layout  
for lfs on lvm would be. I thank you for your time
/
/usr
/usr/local
/usr/src
/var
/var/tmp
/tmp
/opt
/opt/playground (For applications like arduino eclipse and others)
/home 
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page