Skip to content

how to limit scst read/wrtie iops with cgroup-v2? #227

@zhujing3

Description

@zhujing3

Proceed as follows:
using cgroup-v1

on scst server:

  1. add device to vdisk hankder
  2. create a iscsi target,add lun & initor
  3. echo "230:256 1048576" > /sys/fs/cgroup/blkio/blkio.throttle.read_bps_device

on client:

  1. login iscsi target
  2. run dd: dd iflag=direct if=/dev/sdb of=/dev/null bs=4k count=1024

the results are consistent with expectations:

1024+0 records in
1024+0 records out
4194304 bytes (4.2 MB, 4.0 MiB) copied, 4.00212 s, 1.0 MB/s

=================
cgroup v2:

i have add all iscsi/scst/lun-name-process,even all system process to cgroup.procs ,
finally it's only works on scst-server :

dd iflag=direct if=/dev/zd256 of=/dev/null bs=4k count=1024 
1024+0 records in
1024+0 records out
4194304 bytes (4.2 MB, 4.0 MiB) copied, 4.00212 s, 1.0 MB/s

on client, doesn't work at all

=============

the problem:

how to find those process for scst read/write on disk ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions