Hello Friends I am Deepak Saini and today we are discus on the lvm partion
lets start
LVM :-LVM stands for Logical volume management.Lvm is a utility which is enables extending and reducing in partion size.We are using this utility in linux if our one partion is full and we want to extending memory size in this partion we are not able this without LVM partitioning.
How we are create LVM partion in the red hat linux
Logical Drive -------> Physical Voulme -------> Volume Group ------> Logical Volume
Setups
1 1st of all we are create the partions with the help of the fdisk command if you not know how it do then plz first read here
2 Then we are create those partions LVM based to change their hex code with the help of fdisk command
LVM hexacode is 8e check it in the partion tut
3 Then we are create the physical volumes
syntax :- pvcreate <partions name >
We are using the pvdisplay to see the pv
Synatx:- pvdisplay
in this pvcreate is the command and partions name is like /dev/sda5 for one partion and more then one /dev/sda{1,2,3} like that
4 Then we are going for create volume group
syntax:- vgcreate <vg group name> <partion name>
we are using the vgdislay to see the vg
Syntax:- vgdisplay
in this vgcreate is a command and vg group is the name of the volume group and partion name like /dev/sda5 which one you want to create volume group
5 Now the time is come to create the logical volume
syntax:- lvcreate -L <size of lv> -n <Name of lv> <vg path>
we are using lvdisplay to see the lv
syntax :- lv display
in this lvcreate is the command and _l for size of our logical volume and -n for the name of the logical volume
and name of lv is the name of logical volume and vg path is your volume group path you volume is path is like this /dev/vg0 vg0 is here your volume group name which is given by you when you are creating the volume group.
6 for checking you lv or vg create or not do it
syntax:- ll /dev/mapper/
Now how We use that Created Logical volume
1 Format the logical volume
syntax:- mkfs.ext4 /dev/mapper/<your lv name >
2 Then we are mount that partion
syntax:- mkdir /mnt/<dir name>
1st we are create the directory in the mnt dir
syntax:- mount /dev/mapper/<vg name-lv name /mnt/<dir name>
If we want to mount permanently we are entry in the fstab file
syntax:- vim /etc/fstab
Thanks for reading and sorry for My RIP english _/\_ Jai Hind
lets start
LVM :-LVM stands for Logical volume management.Lvm is a utility which is enables extending and reducing in partion size.We are using this utility in linux if our one partion is full and we want to extending memory size in this partion we are not able this without LVM partitioning.
How we are create LVM partion in the red hat linux
Logical Drive -------> Physical Voulme -------> Volume Group ------> Logical Volume
Setups
1 1st of all we are create the partions with the help of the fdisk command if you not know how it do then plz first read here
2 Then we are create those partions LVM based to change their hex code with the help of fdisk command
LVM hexacode is 8e check it in the partion tut
3 Then we are create the physical volumes
syntax :- pvcreate <partions name >
We are using the pvdisplay to see the pv
Synatx:- pvdisplay
in this pvcreate is the command and partions name is like /dev/sda5 for one partion and more then one /dev/sda{1,2,3} like that
4 Then we are going for create volume group
syntax:- vgcreate <vg group name> <partion name>
we are using the vgdislay to see the vg
Syntax:- vgdisplay
in this vgcreate is a command and vg group is the name of the volume group and partion name like /dev/sda5 which one you want to create volume group
5 Now the time is come to create the logical volume
syntax:- lvcreate -L <size of lv> -n <Name of lv> <vg path>
we are using lvdisplay to see the lv
syntax :- lv display
in this lvcreate is the command and _l for size of our logical volume and -n for the name of the logical volume
and name of lv is the name of logical volume and vg path is your volume group path you volume is path is like this /dev/vg0 vg0 is here your volume group name which is given by you when you are creating the volume group.
6 for checking you lv or vg create or not do it
syntax:- ll /dev/mapper/
Now how We use that Created Logical volume
1 Format the logical volume
syntax:- mkfs.ext4 /dev/mapper/<your lv name >
2 Then we are mount that partion
syntax:- mkdir /mnt/<dir name>
1st we are create the directory in the mnt dir
syntax:- mount /dev/mapper/<vg name-lv name /mnt/<dir name>
If we want to mount permanently we are entry in the fstab file
syntax:- vim /etc/fstab
Thanks for reading and sorry for My RIP english _/\_ Jai Hind
0 comments:
Post a Comment