Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env sh
- # init containers
- test -e /cgroups/blkio/weight1-test || mkdir /cgroups/blkio/weight1-test
- echo 1000 /cgroups/blkio/weight1-test/blkio.weight
- test -e /cgroups/blkio/weight2-test || mkdir /cgroups/blkio/weight2-test
- echo 500 /cgroups/blkio/weight2-test/blkio.weight
- # generate big files
- dd if=/dev/zero of=bigfile bs=10M count=1024
- # launch read test
- dd if=bigfile of=/dev/null iflag=direct &
- echo $! > /cgroups/blkio/weight1-test/tasks
- cat /cgroups/blkio/weight1-test/tasks
- dd if=bigfile of=/dev/null iflag=direct&
- echo $! > /cgroups/blkio/weight2-test/tasks
- cat /cgroups/blkio/weight2-test/tasks
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement