LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions
User Name
Password
Linux - Distributions This forum is for Distribution specific questions.
Red Hat, Slackware, Debian, Novell, LFS, Mandriva, Ubuntu, Fedora - the list goes on and on... Note: An (*) indicates there is no official participation from that distribution here at LQ.

Notices


Reply
  Search this Thread
Old 10-17-2005, 02:39 PM   #1
rtspitz
Member
 
Registered: Jan 2005
Location: germany
Distribution: suse, opensuse, debian, others for testing
Posts: 307

Rep: Reputation: 33
lvm2 + snapshots + suse 9.3


hello there !

I'm trying to create a snapshot from a logical volume for backup purposes.
lvm itself works fine.

when creating a snapshot with 'lvcreate' it quite often fails depending on the size
of the snapshot. in general everything below 400MB works quite often, above 400MB mostly fails with something like "vg00/lvol0 already in use".
after the failed snapshot creation, an ordinary logical volume with the size of the wanted snapshot shows up with 'lvs'.

kernel version: 2.6.11.4-21.9-default

LVM version: 2.01.07 (2005-03-08)
Library version: 1.01.00-ioctl (2005-01-17)
Driver version: 4.4.0



on my machine at home with suse 9.2 I usually can create snapshots of arbitrary size.
there are some issues as well, but it seems to be less bug-ridden.

kernel version: 2.6.8-24.18-default

LVM version: 2.00.25 (2004-09-29)
Library version: 1.00.19-ioctl (2004-07-03)
Driver version: 4.1.0



I've learned that this problem has already made it to the redhat forum that deals with the developement of lvm2 - couldn't find any fix there though ;-(


s.o.s.
 
Old 10-17-2005, 07:01 PM   #2
rtspitz
Member
 
Registered: Jan 2005
Location: germany
Distribution: suse, opensuse, debian, others for testing
Posts: 307

Original Poster
Rep: Reputation: 33
some more information:

in case the snapshot creation succeeds the output is as follows:

lvcreate --verbose --size 550m --snapshot /dev/vg00/data
Setting chunksize to 16 sectors.
Finding volume group "vg00"
Rounding up size to full physical extent 552.00 MB
Creating logical volume lvol0
Archiving volume group "vg00" metadata.
Creating volume group backup "/etc/lvm/backup/vg00"
Found volume group "vg00"
Loading vg00-lvol0
Zeroing start of logical volume "lvol0"
Found volume group "vg00"
Removing vg00-lvol0
Found volume group "vg00"
Found volume group "vg00"
Found volume group "vg00"
Loading vg00-data-real
Loading vg00-lvol0-cow
Loading vg00-lvol0
Loading vg00-data
Creating volume group backup "/etc/lvm/backup/vg00"
Logical volume "lvol0" created

lvs
LV VG Attr LSize Origin Snap% Move Copy%
data vg00 owi-a- 1.00G
lvol0 vg00 swi-a- 552.00M data 0.00



in case the snapshot creation fails the output is as follows:

lvcreate --verbose --size 550m --snapshot /dev/vg00/data
Setting chunksize to 16 sectors.
Finding volume group "vg00"
Rounding up size to full physical extent 552.00 MB
Creating logical volume lvol0
Archiving volume group "vg00" metadata.
Creating volume group backup "/etc/lvm/backup/vg00"
Found volume group "vg00"
Loading vg00-lvol0
Zeroing start of logical volume "lvol0"
Found volume group "vg00"
LV vg00/lvol0 in use: not removing
Couldn't deactivate new snapshot.

lvs
LV VG Attr LSize Origin Snap% Move Copy%
data vg00 -wi-a- 1.00G
lvol0 vg00 -wi-a- 552.00M



with --size 550m the ratio of success to failure is about 1:1
the smaller the snapshot size the more likely the creation succeeds.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Webcam snapshots? jmr71769 Linux - Software 1 09-28-2005 05:53 AM
suse 9.3 and root on lvm2 sam_vde SUSE / openSUSE 0 07-14-2005 06:24 AM
DRI snapshots ? sp406 Linux - Hardware 6 12-10-2004 01:50 PM
Taking Snapshots In Enlightenment G24 Linux - General 4 12-27-2003 06:39 AM
web cam snapshots tendaas Linux - Software 0 10-09-2003 09:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions

All times are GMT -5. The time now is 10:03 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration