Bug#878441: lvm2: commands that flush cache do not complete

Michael F. Lamb mike at datagrok.org
Fri Oct 13 18:14:09 UTC 2017


Package: lvm2
Version: 2.02.173-1
Severity: normal

I have an lv with a writeback cache:

$ sudo lvs -a -o+cachemode
  LV                VG    Attr       LSize   Pool        Origin       Data%  Meta%  Move Log Cpy%Sync Convert CacheMode
  ...
  home              linux Cwi-a-C--- 130.00g [homecache] [home_corig] 99.94  1.72            90.77            writeback
  [home_corig]      linux owi-aoC--- 130.00g                                                                           
  [home_corig]      linux owi-aoC--- 130.00g                                                                           
  [home_corig]      linux owi-aoC--- 130.00g                                                                           
  [homecache]       linux Cwi---C--- 104.16g                          99.94  1.72            90.77            writeback
  [homecache_cdata] linux Cwi-ao---- 104.16g                                                                           
  [homecache_cmeta] linux ewi-ao----  20.00m                                                                           

After a hard-reset and an fsck which performed several repairs, I
attempted to change the cachemode from 'writeback' to 'writethrough'.
The progress reaches a certain point but then seems to loop forever.

$ sudo lvchange --cachemode writethrough linux/home
  Flushing 24191 blocks for cache linux/home.
  Flushing 24190 blocks for cache linux/home.
  Flushing 24189 blocks for cache linux/home.
  Flushing 24189 blocks for cache linux/home.
  Flushing 24189 blocks for cache linux/home.
[ ... repeating for hours ... ]
  Flushing 24189 blocks for cache linux/home.
^C  Interrupted...
  Flushing of linux/home aborted.

Then I attempted to remove the cache altogether, with the same result.

$ sudo lvconvert --uncache linux/home
  Flushing 24189 blocks for cache linux/home.
[ ... repeating for hours ... ]
  Flushing 24189 blocks for cache linux/home.
^C  Interrupted...
  Flushing of linux/home aborted.

This issue seems like it might be related to upstream
https://bugzilla.redhat.com/show_bug.cgi?id=1276722 but a comment on
that bug states it was dealt with back in version 2.02.133. (I'm on
2.02.173.)

Note: during this issue, I also experienced bug #857142, so had to
perform the fsck after booting from a debian live usb drive. The
lvchange and lvconvert commands however were performed from this system.

I ran SMART extended diagnostics (including surface scan) on the drives
hosting the PVs for both the cache and home LVs and it reported no
problems. I can't find any I/O errors in my system logs either.

I don't know what initially caused the crash requiring me to hard-reset.
I think it was related to switching my xorg console while using
proprietary video drivers.

I copied (with tar) the data over to a new non-cached lv for my /home,
but I still have the old one around if you would like additional
information about it.

-- System Information:
Debian Release: buster/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'stable'), (90, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.12.0-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages lvm2 depends on:
ii  dmeventd                  2:1.02.142-1
ii  dmsetup                   2:1.02.142-1
ii  init-system-helpers       1.49
ii  libblkid1                 2.29.2-5+b1
ii  libc6                     2.24-17
ii  libdevmapper-event1.02.1  2:1.02.142-1
ii  libdevmapper1.02.1        2:1.02.142-1
ii  liblvm2app2.2             2.02.173-1
ii  libreadline5              5.2+dfsg-3+b1
ii  libudev1                  234-3
ii  lsb-base                  9.20170808

lvm2 recommends no packages.

Versions of packages lvm2 suggests:
ii  thin-provisioning-tools  0.6.1-4+b1

-- no debconf information



More information about the pkg-lvm-maintainers mailing list