« HOWTO: Setup read/write access to local NTFS drives.HOWTO: Extend a partition on LVM. »

HOWTO: Create a Snapshot on LVM.

11/07/08

HOWTO: Create a Snapshot on LVM.

With Hardy all the software should already be installed.

Create a snapshot from the shell prompt. We are going to make a

  • 10Gb snapshot
  • called lv_snap
  • of the real partition /dev/vg01/lv_home

Follow up:

We will then mount it at /mnt/snapshot

sudo  lvcreate -L10G -s -n lv_snap /dev/vg01/lv_home
Ouput from lvcreate
Logical volume "lv_snap" created
sudo mkdir /mnt/snapshot  
sudo mount /dev/vg01/lv_snap /mnt/snapshot  

Do your backups or whatever it was you wanted to do.

sudo umount /mnt/snapshot  
sudo lvremove /dev/vg01/lv_snap
Output from lvremove
Do you really want to remove active logical volume "lv_snap"? [y/n]: y 
Logical volume "lv_snap" successfully removed  

All done :D

No feedback yet

Leave a comment


Your email address will not be revealed on this site.

Your URL will be displayed.
PoorExcellent
(Line breaks become <br />)
(Name, email & website)
(Allow users to contact you through a message form (your email will not be revealed.)
What can birds and aeroplanes both do?
antispam test