chrt

来源:互联网 发布:10 100base tx端口 编辑:程序博客网 时间:2024/06/16 07:43

管理进程的实时属性:sets  or  retrieves  the real-time scheduling attributes of an existing PID or runs COMMAND with the given attributes.  Both
       policy (one of SCHED_OTHER, SCHED_FIFO, SCHED_RR, or SCHED_BATCH) and priority can be set and retrieved.

PTIONS
       -p, --pid
              operate on an existing PID and do not launch a new task

       -b, --batch
              set scheduling policy to SCHED_BATCH

       -f, --fifo
              set scheduling policy to SCHED_FIFO

       -m, --max
              show minimum and maximum valid priorities, then exit

       -o, --other
              set policy scheduling policy to SCHED_OTHER

       -r, --rr
              set scheduling policy to SCHED_RR (the default)

       -h, --help
              display usage information and exit

       -v, --version
              output version information and exit

USAGE
       The default behavior is to run a new command::
              chrt [prio] [command] [arguments]

       You can also retrieve the real-time attributes of an existing task:
              chrt -p [pid]

       Or set them:
              chrt -p [prio] [pid]


举例:

1、chrt -f 50 /usr/mysql/bin/ndb_mgmd --nowait-nodes 2 --disable-config-cache --initial --config-file=/usr/dhafw/data/mysql/config.ini --nodaemon

5863  5863 FF      50   -  90   1  1.4 FF  Ssl  poll_schedule_ndb_mgmd


2、chrt -p 30756
pid 30756's current scheduling policy: SCHED_OTHER
pid 30756's current scheduling priority: 0


原创粉丝点击