-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create dm-cache and test failed #61
Comments
dmtest sets up caches etc itself, just put the raw block devices in the config (or a slice of them). The error you're getting is to do with sudo, nothing to do with dmtest. |
@jthornber I modified config to contain only raw device
Then run a basic task with rvmsudo(failed without rvmsudo) It still got something wrong
I'm a newbie so don't know where to debug |
Do you have cache_restore in your path?
…On Thu, 28 May 2020 at 09:15, lampahome ***@***.***> wrote:
@jthornber <https://github.com/jthornber>
Excuse me, somethin weird still found.
I modified config to contain only raw device
I'm sure /dev/sdb and /dev/sdc are all ssd.
profile :ssd do
metadata_dev '/dev/sdb'
data_dev '/dev/sdc'
end
default_profile :ssd
Then run a basic task with rvmsudo(failed without rvmsudo)
rvmsudo dmtest run --suite cache --profile ssd -t BackgroundWritebackTests
It still got something wrong
Warning: can not check `/etc/sudoers` for `secure_path`, falling back to call via `/usr/bin/env`, this breaks rules from `/etc/sudoers`. Run:
export rvmsudo_secure_path=1
to avoid the warning, put it in shell initialization file to make it persistent.
In case there is no `secure_path` in `/etc/sudoers`. Run:
export rvmsudo_secure_path=0
to avoid the warning, put it in shell initialization file to make it persistent.
Loaded suite cache
BackgroundWritebackTests
cache_remains_clean_through_reload_mq_1...16357 dirty blocks
8586 dirty blocks
885 dirty blocks
0 dirty blocks
0 dirty blocks
No input files found for test-dev-184974
PASS
cache_remains_clean_through_reload_mq_2...#<Test::Unit::Error:0x00007f8aa0005500
@exception=
#<ProcessControl::ExitError: command failed: cache_restore --metadata-version 2 -i metadata.xml -o /dev/mapper/test-dev-518937>,
@test_name=
"test_cache_remains_clean_through_reload_mq_2(BackgroundWritebackTests)">
FAIL
cache_remains_clean_through_reload_smq_1...16362 dirty blocks
8893 dirty blocks
1324 dirty blocks
0 dirty blocks
0 dirty blocks
No input files found for test-dev-992634
PASS
cache_remains_clean_through_reload_smq_2...#<Test::Unit::Error:0x00000000028a0cd0
@exception=
#<ProcessControl::ExitError: command failed: cache_restore --metadata-version 2 -i metadata.xml -o /dev/mapper/test-dev-378744>,
@test_name=
"test_cache_remains_clean_through_reload_smq_2(BackgroundWritebackTests)">
FAIL
clean_a_cache_with_large_blocks...#<Test::Unit::Error:0x00000000029c7f28
@exception=
#<ProcessControl::ExitError: command failed: cache_restore --metadata-version 2 -i metadata.xml -o /dev/mapper/test-dev-205475>,
@test_name="test_clean_a_cache_with_large_blocks(BackgroundWritebackTests)">
FAIL
clean_data_never_gets_written_back_mq_1...No input files found for test-dev-623727
PASS
clean_data_never_gets_written_back_mq_2...#<Test::Unit::Error:0x0000000002bd3178
@exception=
#<ProcessControl::ExitError: command failed: cache_restore --metadata-version 2 -i metadata.xml -o /dev/mapper/test-dev-997659>,
@test_name=
"test_clean_data_never_gets_written_back_mq_2(BackgroundWritebackTests)">
FAIL
...
I'm a newbie so don't know where to debug
Could your teach me why this FAIL happened?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ2DV3ZJXGAORG7QDB3RTYMQ7ANCNFSM4NMWSFQA>
.
|
Yes
|
Next thing to do is look at the log in ~/.dmtest/logs and see why
cache_restore failed. You can also do this via your web browser using
'dmtest serve'.
…On Thu, 28 May 2020 at 09:25, lampahome ***@***.***> wrote:
Yes
Host:/git/device-mapper-test-suite$ which cache_restore
/usr/sbin/cache_restore
Host:/git/device-mapper-test-suite$ ll /usr/sbin/cache_restore
lrwxrwxrwx 1 root root 11 十 25 2015 /usr/sbin/cache_restore -> pdata_tools*
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ6FC7MZN3UJHFK62B3RTYNWTANCNFSM4NMWSFQA>
.
|
Found it
Is that version too old? |
cache_restore --version,
I'm running 0.8.5 here.
…On Thu, 28 May 2020 at 09:32, lampahome ***@***.***> wrote:
Found it
...
D, [2020-05-28T16:18:13.978003 #13488] DEBUG -- : executing: 'cache_restore --metadata-version 2 -i metadata.xml -o /dev/mapper/test-dev-513496'
D, [2020-05-28T16:18:13.980712 #13488] DEBUG -- : stderr:
cache_restore: unrecognized option '--metadata-version'
Usage: cache_restore [options]
Options:
{-h|--help}
{-i|--input} <input xml file>
{-o|--output} <output device or file>
{-q|--quiet}
{-V|--version}
{--debug-override-metadata-version} <integer>
{--omit-clean-shutdown}
Is that version too old?
Mine OS is ubuntu 16.04
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ5LNKAAZZPB4LECCATRTYOQBANCNFSM4NMWSFQA>
.
|
Do you build from its github directly? |
Yes
…On Thu, 28 May 2020 at 09:35, lampahome ***@***.***> wrote:
$ cache_restore --version
0.5.6
Do you build from its github directly?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ6WD243XJKAUFXY74LRTYO4DANCNFSM4NMWSFQA>
.
|
In cache suit BackgroundWritebackTests, some still failed
I take a look at dirty_data_always_gets_written_back_mq_1 log:
I don't understand what it means |
It means an assertion has failed (expected 16384 but was 0). You'll have
to look at background_writeback_tests.rb for more info.
What are you trying to do? These tests are for people developing device
mapper targets (ie. kernel programmers).
…On Thu, 28 May 2020 at 09:49, lampahome ***@***.***> wrote:
In cache suit BackgroundWritebackTests, some still failed
BackgroundWritebackTests
cache_remains_clean_through_reload_mq_1
cache_remains_clean_through_reload_mq_2
cache_remains_clean_through_reload_smq_1
cache_remains_clean_through_reload_smq_2
clean_a_cache_with_large_blocks
clean_data_never_gets_written_back_mq_1
clean_data_never_gets_written_back_mq_2
clean_data_never_gets_written_back_smq_1
clean_data_never_gets_written_back_smq_2
dirty_data_always_gets_written_back_mq_1 FAIL
dirty_data_always_gets_written_back_mq_2 FAIL
dirty_data_always_gets_written_back_smq_1 FAIL
dirty_data_always_gets_written_back_smq_2 FAIL
I take a look at dirty_data_always_gets_written_back_mq_1 log:
... ...
D, [2020-05-28T16:41:51.280358 #21050] DEBUG -- : stdout:
0 937703088 cache 8 58/1024 128 16380/16384 17 29 0 0 8 4 0 1 writeback 2 migration_threshold 1024 mq 10 random_threshold 0 sequential_threshold 0 discard_promote_adjustment 0 read_promote_adjustment 0 write_promote_adjustment 0 rw -
D, [2020-05-28T16:41:51.281044 #21050] DEBUG -- : executing: 'dmsetup remove test-dev-539956'
D, [2020-05-28T16:41:51.366892 #21050] DEBUG -- : executing: 'cache_check /dev/mapper/test-dev-585676'
D, [2020-05-28T16:41:51.438179 #21050] DEBUG -- : stderr:
examining superblock
examining mapping array
examining hint array
examining discard bitset
D, [2020-05-28T16:41:51.637689 #21050] DEBUG -- : stdout:
=== dm-2 ===
CPU 0: 56 events, 3 KiB data
CPU 1: 0 events, 0 KiB data
CPU 2: 16408 events, 770 KiB data
CPU 3: 0 events, 0 KiB data
Total: 16464 events (dropped 0), 772 KiB data
D, [2020-05-28T16:41:51.642712 #21050] DEBUG -- : executing: 'dmsetup remove test-dev-393569'
D, [2020-05-28T16:41:51.666299 #21050] DEBUG -- : executing: 'dmsetup remove test-dev-464559'
D, [2020-05-28T16:41:51.690019 #21050] DEBUG -- : executing: 'dmsetup remove test-dev-585676'
E, [2020-05-28T16:41:51.720470 #21050] ERROR -- : Failure:
test_dirty_data_always_gets_written_back_mq_1(BackgroundWritebackTests)
[/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/tests/cache/background_writeback_tests.rb:83:in `block in dirty_data_always_gets_written_back'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/ensure_elapsed.rb:13:in `ensure_elapsed_time'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/cache_stack.rb:75:in `block in activate_support_devs'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/ensure_elapsed.rb:13:in `ensure_elapsed_time'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/device-mapper/lexical_operators.rb:42:in `block in with_devs'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/prelude.rb:6:in `bracket'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/device-mapper/lexical_operators.rb:37:in `with_devs'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/cache_stack.rb:67:in `activate_support_devs'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/tests/cache/background_writeback_tests.rb:72:in `dirty_data_always_gets_written_back'
/usr/share/rvm/gems/ruby-2.5.3/gems/device_mapper_test_suite-0.0.1/lib/dmtest/test-utils.rb:25:in `block (2 levels) in define_tests_across']:
<16384> expected but was
<0>.
I, [2020-05-28T16:41:51.720736 #21050] INFO -- : Peak bufio allocation was 458752
I don't understand what it means
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQZNIDPM7JQILGMPSGLRTYQTNANCNFSM4NMWSFQA>
.
|
I want to try my custom dm-cache driver, so want to find tool to test if driver works Unfortunately, I'm not familiar with ruby |
I checked background_writeback_tests.rb
My |
Which kernel are you using?
…On Thu, 28 May 2020 at 10:19, lampahome ***@***.***> wrote:
I checked background_writeback_tests.rb
If fails here:
def dirty_data_always_gets_written_back(policy, metadata_version)
...
assert_equal(cache_size / block_size, filter_writes(traces[0]).size)
end
end
My cache_size is 2097152, block_size is 128, so cache_size / block_size
is 16384
Is that possible to modify that by arguments? or other ways?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQZSP7Y4BCVAVB7BLADRTYUC7ANCNFSM4NMWSFQA>
.
|
And I also enable dm-cache, dm-verity, dm-dust when make menuconfig. Can I know your kernel version? I wanna tried . |
ok, so not too old.
If you're doing kernel development I strongly recommend you do it within a
virtual machine. That way you don't risk trashing your real machine.
Are you modifying my existing dm-cache, or writing a new policy for it, or
writing something new from scratch?
…On Thu, 28 May 2020 at 10:28, lampahome ***@***.***> wrote:
Linux pahome-QW09 5.4.20+ #1
<#1> SMP Wed
May 27 17:07:17 CST 2020 x86_64 x86_64 x86_64 GNU/Linux
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ4LBL62K4TU4IGEOMTRTYVD5ANCNFSM4NMWSFQA>
.
|
No, I don't modified anything about kernel 5.4 and your code. |
"I want to try my custom dm-cache driver" <- what did you mean by this
then?
…On Thu, 28 May 2020 at 10:35, lampahome ***@***.***> wrote:
Are you modifying my existing dm-cache, or writing a new policy for it, or
writing something new from scratch?
No, I don't modified anything about kernel 5.4 and your code.
Just enable dm-cache...etc and reboot. Then dmtest run --suite cache...
like above mentioned.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ3PKOYC3IFBCEB4LJTRTYV57ANCNFSM4NMWSFQA>
.
|
In the future, I want to re-write dm-cache for my job. BTW, I saw |
How will your rewrite differ? Between dm-cache and dm-writecache I think
we've got a really strong offering atm.
…On Thu, 28 May 2020 at 10:40, lampahome ***@***.***> wrote:
"I want to try my custom dm-cache driver" <- what did you mean by this
*In the future*, I want to re-write dm-cache for my job.
So I first use upstream dm-cache and test it by device-mapper-test-suite
BTW, I saw cache_size and block_size was defined by function, maybe
that's why I always failed.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ7EVCQ6UGM4X5YYITDRTYWSLANCNFSM4NMWSFQA>
.
|
The target of rewrite maybe combine flashcache and dm-cache |
Is that bug? In ./lib/dmtest/tests/cache/fio_tests.rb
function arguments number different there |
yes, pass in sub_vol_size
…On Thu, 28 May 2020 at 10:54, lampahome ***@***.***> wrote:
Is that bug?
In ./lib/dmtest/tests/cache/fio_tests.rb
def run_fio(dev, name, file_size) <- 3 arguments
outfile = AP("fio-#{name}.out")
size_in_meg = file_size / meg(1)
...
def baseline(dev, name)
sub_vol_size = meg(1024 + 128)
vg = TinyVolumeManager::VM.new
vg.add_allocation_volume(dev)
vg.add_volume(linear_vol("vol", sub_vol_size))
with_dev(vg.table("vol")) do |vol|
run_fio(vol, name) <- 2 arguments
end
end
function arguments number different there
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ52LI4PV62CPJNZM2LRTYYFXANCNFSM4NMWSFQA>
.
|
If I want to test dm-cache in kernel 5.4
|
I'd start with:
dmtest run --suite cache -t FIOTests -n fio_across_cache_size_smq
…On Thu, 28 May 2020 at 11:21, lampahome ***@***.***> wrote:
If I want to test dm-cache in kernel 5.4
What item should I test in cache suite?
BackgroundWritebackTests <-- passed
BurstyWriteTests
DTTests
DiscardTests
FIOTests <-- fail in fio_on_slow and fio_on_fast
GitExtractTests
IOUseTests
InvalidateCBlocksTests
LargeConfigTests
MetadataScalingTests
MetadataVersionTests
NeedsCheckTests
NoCleanShutdownTests
PassthroughTests
PolicySwitchTests
ResizeTests
SMQComparisonTests
SmallConfigTests
ToolsTests
WriteThroughTests
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQZWWDDZLB44BEL46STRTY3JZANCNFSM4NMWSFQA>
.
|
It seems fio_on_slow and fio_on_fast of FIOTests will failed cuz of fallocate too much space This grab the fio_on_slow.log from beginning to bug point:
Is there any way to avoid this? Like space maximum? |
Sorry, where to download dt in Ubuntu?
|
… On Thu, 28 May 2020 at 11:42, lampahome ***@***.***> wrote:
Sorry, where to download dt in Ubuntu?
Looks like I download wrong binary
It shows
Host:~/git/qnap_linux_5_4$ dt help
DITrack command-line client, version 0.8
General usage:
dt <command> [<options>] [<args>]
Available commands:
act
cat
commit, ci
help
list, ls
new
remove, rm
status, st
update, up
Type 'dt help <command>' for help on specific command.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#61 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOSQ5Z4564E62CSLCKSGTRTY52DANCNFSM4NMWSFQA>
.
|
Do you have any ideas about the fio_on_fast & fio_on_slow issues? |
When I run task BurstyWriteTests in cache suite, it fails. Take a look at one of the log smallfile_cache_mq_1.log:
Where to find the smallfile_cli.py? |
I create dm-cache with SSD RAID0(/dev/md1) and HDD(/dev/sdd)
Then write new profile
ssd
in~/.dmtest/config
:And run
rvmsudo dmtest run --suite cache --profile ssd -t FIOTests
But it shows all error:
Why it shows out of free space? and other errors?
Is there anything wrong?
The text was updated successfully, but these errors were encountered: