Create lvm redhat

| April 30, 2011

Using fdisk make a partition and toggle that partition to LINUX LVM (8e)

#vgscan

/* it will make a folder in /etc ie /etc/lvmtab.d */

#pvcreate /dev/hda10

/* to create a pysical volume */

#pvdisplay /dev/hda10

/*to display the size of the physical volume */

#vgcreate test /dev/dha10

/* to create volume group whose name test */

#vgdisplay test

/* to display the details of volume group created */

#lvcreate -L 100M -n data test

/* to create logical volume of size 100 MB with name as data , /etc/test/data */

#lvdisplay /dev/test/data

#mke2fs -j /dev/test/data

/ * to convert logical partition to ext3 filesystem*/

#mount /dev/test/data /mnt

Follow the stepss and u will success !!!!!!!!!!!!!!!!

bobsss

To resize the logical volume but make sure to unmount ie if /dev/test/data is mounted it should be umounted before resizing

#e2fsadm -L + 50M /dev/test/data

or

#e2fsadm -L – 50M /dev/test/data

#e2fsadm -L +50M /dev/test/data

Tags: , ,

Category: Linux Administration

Comments are closed.