how to use lvconvert command and its examples

  • About lvconvert : To convert a logical volume from linear to mirror or snapshot
  • It comes from “lvm2-2.02.72” package.
  • Configuration Files:
  • Path: /sbin/lvconvert


1. To specify the degree of mirror to create

$ lvconvert -m 1
$ lvconvert –mirrors 1

2. To specify the type of log to use

$ lvconvert –mirrorlog disk
$ lvconvert –mirrorlog core
$ lvconvert –mirrorlog mirrored
$ lvconvert –corelog 

3. To divide the mirror into regions

$ lvconvert -R MirrorLogRegionSize
$ lvconvert –regionsize MirrorLogRegionSize 

4. To run the daemon in background

$ lvconvert -b
$ lvconvert –background 

5. To report progress as a percentage at regular intervals

$ lvconvert -i Seconds
$ lvconvert –interval Seconds 

5. To disable udev synchronization

$ lvconvert –noudevsync

 6. To split off mirror images to form a new logical volume

$ lvconvert –splitmirrors Images

 7. To apply name to a logical volume which has been split off from a mirror logical volume

$ lvconvert -n name

8. To Create  a  snapshot from existing logical volume using another existing logical volume as its origin

$ lvconvert -s
$ lvconvert –snapshot 

9. To Power of 2 chunk size for the snapshot logical volume between 4k and 512k

$ lvconvert -c ChunkSize
$ lvconvert –chunksize ChunkSize 

10. To Controls zeroing of the first KB of data in the snapshot

$ lvconvert -Z y|n
$ lvconvert –zero y|n 

11. To Merges  a snapshot into its origin volume.

$ lvconvert –merge

12. To Repair  a mirror after suffering a disk failure.

$ lvconvert –repair

Related Commands: lvm, vgcreate, lvremove, lvrename, lvextend, lvreduce, lvdisplay, lvscan 

2 thoughts on “how to use lvconvert command and its examples

Leave a Reply

Your email address will not be published. Required fields are marked *