nixosTests.misc: fix blkio sub-test with newer kernels

The blkio.sectors file is no longer provided; by quick search:
https://issues.apache.org/jira/browse/MESOS-9848
so hopefully it's sufficient to test existence of this other file:
https://www.kernel.org/doc/html/v5.4/admin-guide/cgroup-v1/blkio-controller.html#common-files-among-various-policies

Originally this sub-test was added in 58e40f84.
This commit is contained in:
Vladimír Čunát 2020-02-02 13:16:30 +01:00
parent f350a6f42c
commit 1af60850c5
No known key found for this signature in database
GPG key ID: E747DF1F9575A3AA

View file

@ -77,7 +77,7 @@ import ./make-test-python.nix ({ pkgs, ...} : rec {
machine.succeed('[ -x "$(cat /proc/sys/kernel/poweroff_cmd)" ]')
with subtest("whether the blkio controller is properly enabled"):
machine.succeed('[ -n "$(cat /sys/fs/cgroup/blkio/blkio.sectors)" ]')
machine.succeed("[ -e /sys/fs/cgroup/blkio/blkio.reset_stats ]")
with subtest("whether we have a reboot record in wtmp"):
machine.shutdown