]> sourceware.org Git - lvm2.git/commitdiff
cachevol: use writethrough for partial removal
authorZdenek Kabelac <zkabelac@redhat.com>
Sat, 12 Oct 2019 21:38:56 +0000 (23:38 +0200)
committerZdenek Kabelac <zkabelac@redhat.com>
Mon, 14 Oct 2019 13:15:14 +0000 (15:15 +0200)
Instead of using 'noflush' option, switch cache_mode into WRITETHROUGH
which does not require flushing, when user confirmed he does not
want flushing for WRITEBACK (because of (partially) missing caching PV)

tools/lvconvert.c

index 14663e8df3a1bce629741d3a35ac8d8de96e57e7..f875ac7ad75aff43fe0fe08f3e37b0f8654e9edf 100644 (file)
@@ -1875,7 +1875,8 @@ static int _lvconvert_split_and_keep_cachevol(struct cmd_context *cmd,
                        return 0;
                }
 
-               noflush = 1;
+               /* Switch internally to WRITETHROUGH which does not require flushing */
+               cache_seg->cache_mode = CACHE_MODE_WRITETHROUGH;
        }
                                
        if (!lv_detach_cache_vol(lv, noflush))
This page took 0.037908 seconds and 5 git commands to generate.