lvm snapshots take almost 10 minutes

Bug #110380 reported by Craig Box
2
Affects Status Importance Assigned to Milestone
lvm2 (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

dmsetup, libdevmapper1.02: 1.02.08-1ubuntu10
lvm-common: 1.5.20ubuntu12
lvm2: 2.02.06-2ubuntu9

Running "lvcreate -s" to create an LVM snapshot takes about 10 minutes to complete, where it should be instantaneous. stracing lvcreate shows a lot of waiting for devices to exist (VG name is mlc2, snapshot name strace-test)

stat64("/dev/mapper/mlc2-strace--test", 0xbfb917c8) = -1 ENOENT (No such file or directory)
nanosleep({0, 10000000}, NULL) = 0
stat64("/dev/mapper/mlc2-strace--test", 0xbfb917c8) = -1 ENOENT (No such file or directory)
nanosleep({0, 20000000}, NULL) = 0

Then does a lot of waiting for another device:

stat64("/dev/mapper/mlc2-strace--test-cow", 0xbfb917d8) = -1 ENOENT (No such file or directory)
nanosleep({0, 10000000}, NULL) = 0
stat64("/dev/mapper/mlc2-strace--test-cow", 0xbfb917d8) = -1 ENOENT (No such file or directory)
nanosleep({0, 20000000}, NULL) = 0

etc.

In accordance with bug 38409, I currently have "KERNEL=="dm-[0-9]*", OPTIONS+="ignore_device"" set in /etc/udev/rules.d/20-names.rules. No other changes have been made to udev. I will try removing the change (which should no longer be required) on my test box.

Side note: due to a bug in my rotation script, I found I had about 20 snapshots on a machine the other day. It then wouldn't boot, as per bug 103866 - when I removed all the snapshots, mounting the volume of which all the snapshots are taken, worked.

Revision history for this message
Craig Box (craig.box) wrote :

OK, the problem is definitely the ignore_device in udev. I deliberately didn't remove this workaround when I upgraded because I knew it always had to be put in there to fix bug 38409 (in the past). I'm not sure if there is any worth in detecting it in the postinstall or anything, but it causes bug 103866 for me as well, so it might be reasonably common.

Revision history for this message
Daniel T Chen (crimsun) wrote :

Is this symptom still reproducible in 8.10 beta?

Changed in lvm2:
status: New → Incomplete
Revision history for this message
Craig Box (craig.box) wrote :

I no longer have the capacity to test this, so if someone else subscribed to this bug could investigate, it would be appreciated.

Revision history for this message
Neil Munro (neilmunro-deactivatedaccount) wrote :

Thank you for reporting this bug and taking the time to help make Ubuntu better.

I am closing this bug due to it's inactivity. Should this reoccur please feel free to reopen this bug.

Changed in lvm2 (Ubuntu):
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.