All of lore.kernel.org
 help / color / mirror / Atom feed
From: Zdenek Kabelac <zkabelac@sourceware.org>
To: lvm-devel@redhat.com
Subject: main - test: check writecache profile support
Date: Wed, 26 Jan 2022 14:10:33 +0000 (GMT)	[thread overview]
Message-ID: <20220126141033.9A3EC385041C@sourceware.org> (raw)

Gitweb:        https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=89cec5b65af5533bcde358d8d4f7d1d5701a341b
Commit:        89cec5b65af5533bcde358d8d4f7d1d5701a341b
Parent:        b95506815fa149cf135687cbe047b7bdfcd6e00f
Author:        Zdenek Kabelac <zkabelac@redhat.com>
AuthorDate:    Mon Jan 24 14:49:53 2022 +0100
Committer:     Zdenek Kabelac <zkabelac@redhat.com>
CommitterDate: Wed Jan 26 15:09:58 2022 +0100

test: check writecache profile support

FIXME
---
 test/shell/profiles-cache.sh  | 10 ++++++++++
 test/shell/writecache-misc.sh |  6 ++++++
 2 files changed, 16 insertions(+)

diff --git a/test/shell/profiles-cache.sh b/test/shell/profiles-cache.sh
index 9e17ebf60..47a5cdf2f 100644
--- a/test/shell/profiles-cache.sh
+++ b/test/shell/profiles-cache.sh
@@ -43,6 +43,9 @@ allocation {
 			sequential_threshold = 100
 			random_threshold = 200
 		}
+		writecache {
+			high_watermark = 60
+		}
 	}
 }
 EOF
@@ -58,6 +61,13 @@ EOF
 
 aux prepare_vg 2 1000000
 
+# Check writecache read data from profile
+lvcreate -n $lv1 -l 4 -an $vg "$dev1"
+lvcreate -y --type writecache -l 4 --cachevol $lv1 -n $lv2 --metadataprofile $PFILE $vg "$dev2"
+check lv_field $vg/$lv2 cachesettings "high_watermark=60"
+lvremove -y $vg
+exit
+
 # Check chunk_size is grabbed from configuration
 lvcreate -L1G --config 'allocation/cache_pool_chunk_size=512' --type cache-pool $vg/cpool
 check lv_field $vg/cpool chunksize "512.00k"
diff --git a/test/shell/writecache-misc.sh b/test/shell/writecache-misc.sh
index 80b793256..f62974c54 100644
--- a/test/shell/writecache-misc.sh
+++ b/test/shell/writecache-misc.sh
@@ -52,6 +52,12 @@ aux prepare_devs 4
 vgcreate $vg "$dev1" "$dev2" "$dev3" "$dev4"
 
 
+# Create writecache without a specified name so it gets automatic name
+lvcreate -n $lv1 -l 4 -an $vg "$dev1"
+lvcreate -y --type writecache -l 4 --cachevol $lv1 $vg "$dev2"
+check lv_exists $vg lvol0
+lvremove -y $vg
+
 #
 # Test pvmove with writecache
 #



                 reply	other threads:[~2022-01-26 14:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220126141033.9A3EC385041C@sourceware.org \
    --to=zkabelac@sourceware.org \
    --cc=lvm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.