Description of problem: Reporting of status with noflush (dmsetup status --noflush) seems to never get the 'correct' status even after long waiting and no i/o to thin-pool. Flushing status is needed to enforce commit. Example of issue (having VG 'vg') lvcreate -T -L10 vg/pool -V9 -n testLV dd if=/dev/zero of=/dev/vg/testLV bs=1M count=9 lvs -a shows 90% of data thin-pool usage -> exact and 100% of data thin volume usage -> exact let's discard thin device: blkdiscard /dev/vg/testLV lvs -a shows 90% of data thin-pool usage -> this is not exact and 0% of data thin volume usage -> this is OK lvm2 dropped usage of 'flushing' when obtaining status and there is opened bug 1358314 to rather add support for some 'explicit' flushing logic later. But there was assumption that in some short period of time we will obtain valid data anyway - but even after minutes 'dmsetup status --noflush / lvs -a' is still showing 144/160 usage. after 'dmsetup status' data are instantly corrected to 0/160. Version-Release number of selected component (if applicable): 4.10.0-0.rc2.git2.1.fc26.x86_64 How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
I've added this test to the test suite. It passes with my upstream kernel. Checking with RHEL next. https://github.com/jthornber/device-mapper-test-suite/commit/272b0e5b78e15f773ea7bccaea293c8a47e685
It fails with RHEL
Still reproducible/observed with: 4.12.0-0.rc6.git3.2.fc27.x86_64
This issue is reproducible on current upstream kernel: 5.9.0-0.rc6.13.fc34.x86_64