I am working on getting LVM on my notebook. The easiest way may be to use the whole disk except for a small /boot partition which needs to be outside the LVM but with an initrd compiled with LVM support :
What LVM does is give more flexible partitions. Just think of them as logical volumes in an extended partition (the volume group). I think that is the best way to describe them. It is also possible to add extra space to them if needed, or even add partitions to make them bigger. That is how I see it. I hope I am right. If I am not I am sure someone will correct me.
I hope this helps.
Andy.
This User Gave Thanks to dragonnefyre For This Post:
Hi all,
yes this is a linux question :) but also a LVM question.
Some time ago, I saw an posting, LVM Version 1.X is abe to handle multiple physical pathes to a disk with using md devices. Is this right ?
Now I am planing to create a san and want use linux fileservers with LVM v1.X and most... (1 Reply)
I'm setting up a CentOS 5 server that will be connected to an HP EVA4000. My previous experience is with an HP VA7400 and HP-UX. In HP-UX I can add "alternate paths" to a volume group in order to have redundant paths to the SAN via dual fiber channel HBAs just by either adding them with... (3 Replies)
Not real Linux expert but here is the problem.
Shutdown this machine and then it would not reboot.
From everything I can tell it looks like the journal file in the logical volume is corrupted. I have tried everything I can think of to get the volume mounted.
Anybody have any ideas on how... (19 Replies)
Hi,
What do you means to create so OS Linux directories under LVM?
So, I've installed my machine :
df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda3 97943628 524316 92443984 1% /
udev 4023852 168 4023684 1% /dev... (1 Reply)
I've three partitions on /dev/sda: sda1, sda2 sda3. There is FREE space between sda2 and sda3 and sda3 ends on the last sector. sda2 and sda3 have the same number of sectors allocated and so are the exact same size.
/dev/sda2 is already part of the VG VolGroup. However, what puzzles me is that... (0 Replies)
My root file system is of type LVM. i wanna shrink it but unable to do so.
When i give the below command:
resize2fs /dev/mapper/VolGroup00-VolLog00 10000M
it messages that online shrink can't can't be done as the logical volume is mounted on /. i switched to single user mode by giving command:... (2 Replies)
Hi,
a little while ago, one of the GPT Partitioned hard disk had gone faulty in a Mirror RAID and is now successfully replaced.
here is how I did that.
1) created identical partition table on the new disk.
2) attached the mirrors using md commands.
The whole procedure is given... (5 Replies)
Hi,
I need a suggesstion i have 2 disk if i installed OS / root partition by making Lvm in one disk and data in other disk also with the lvm, means 2 different lvms.
Is making LVM partition for OS disk will the performacne will be good?
Can i make 2 different lvm one is for OS and other for... (1 Reply)
Discussion started by: Rahulne25
1 Replies
LEARN ABOUT REDHAT
lvmcreate_initrd
LVMCREATE_INITRD(8) System Manager's Manual LVMCREATE_INITRD(8)NAME
lvmcreate_initrd - create an initial ramdisk to boot with root on a logical volume
SYNOPSIS
lvcmreate_initrd [-i|--iop IOP] [-D|--devfs] [-v|--verbose] [-V|--version] [KernelVersion]
DESCRIPTION
lvmcreate_initrd creates a new compressed initial ramdisk /boot/initrd-lvm-KernelVersion.gz. The initial ramdisk contains all necessary
binaries, shared libraries and a linuxrc file to switch to a logical volume based root filesystem. To build an initial ramdisk for a ker-
nel other than the one currently running add the KernelVersion parameter (e.g. lvmcreate_initrd 2.3.25) on the command line.
OPTIONS
-h, --help
Print a usage message on standard output and exit.
-i, --iop IOP
Specify the LVM kernel IOP version if you are using wrapper scripts in /sbin. This is only necessary if you are building an initrd
for a kernel other than the current one, and you have tools for multiple IOP versions installed.
-D, --devfs
Force the use of devfs when building the initrd. lvmcreate_initrd by default probes for devfs by checking for /dev/.devfsd, which
is created by devfsd when it is running. This option will force lvmcreate_initrd to do this, when devfsd is not currently running.
-v, --verbose
Gives verbose runtime information about the creation of the ram disk image.
-V, --version
Print version number and exit successfully.
The necessary actions to change your system into a "root on logical volume" one are:
Create a small (~20MB) partition which is BIOS reachable to hold the /boot filesystem (if you already have a small partition based root
filesystem this can be used instead). If you want to boot standalone from this partition in an emergency, copy all the necessary binaries
and libraries to that filesystem as well and create a corresponding /etc/lilo.conf entry. In order to be able to edit lilo.conf when booted
standalone, you should move /etc/lilo.conf to /boot/lilo.conf and create a symbolic link to it in /etc. This is not needed if you have a
boot/root floppy which contains the LVM binaries and the library.
Create all logical volumes you need (for root, usr, opt etc.), create filesystems in them, mount them and transfer all files from the par-
tition based filesystems into the logical volume based ones.
Set up your /etc/lilo.conf with a boot configuration like:
image = /boot/vmlinuz
initrd = /boot/initrd-lvm-KernelVersion.gz
root = /dev/YourVG/YourRootLV
label = rootonlv
append = 'ramdisk_size=8192'
Replace YourVG and YourRootLV by your actual volume group and root logical volume names. You also need to change the ramdisk size to be at
least as large as that reported while lvmcreate_initrd is run. If you have enough memory, it is OK if the ramdisk size in /etc/lilo.conf
is larger than what lvmcreate_initrd reports (the memory is freed after booting). Also, your /etc/fstab in the root logical volume should
contain entries for the root LV, and the boot partition, along with any other LVs you have configured:
/dev/YourVG/YourRootLV / ext2 defaults 0 1
/dev/YourBootPartition /boot ext2 defaults 0 2
/dev/YourVG/YourUsrLV /usr ext2 defaults 0 3
/dev/YourVG/YourOptLV /opt ext2 defaults 0 4
etc.
You can use other supported filesystem types as well (e.g. reiserfs) if you have support for those in your kernel. Run lilo, reboot and
try...
The partitions containing the former /usr, /opt etc. filesystems can now be used as physical volumes. Use pvcreate(8) to turn them into
PVs and then use vgextend(8) to add them to e.g. YourVG.
DIAGNOSTICS
lvcmcreate_initrd returns 0 for success. 1 is returned in all other cases.
SEE ALSO lilo(8), lilo.conf(5), fstab(5), lvm(8), pvcreate(8), vgextend(8), lvcreate(8), vgcreate(8)AUTHOR
Heinz Mauelshagen <Linux-LVM@Sistina.com>
Heinz Mauelshagen LVM TOOLS LVMCREATE_INITRD(8)