Lines Matching +full:re +full:- +full:attached
6 Documentation/admin-guide/cgroup-v1/cpusets.rst
12 Portions Copyright (c) 2004-2006 Silicon Graphics, Inc.
42 ----------------------
56 schedules a resource or applies per-cgroup limits, but it may be
62 hierarchy, and a set of subsystems; each subsystem has system-specific
63 state attached to each cgroup in the hierarchy. Each hierarchy has
69 User-level code may create and destroy cgroups by name in an
79 access. For example, cpusets (see Documentation/admin-guide/cgroup-v1/cpusets.rst) allow
83 .. _cgroups-why-needed:
86 ----------------------------
89 Linux kernel, mainly for resource-tracking purposes. Such efforts
103 different subsystems - having parallel hierarchies allows each
111 would be attached to the same hierarchy.
115 university server with various users - students, professors, system
125 In addition (system tasks) are attached to topcpuset (so
173 ---------------------------------
177 - Each task in the system has a reference-counted pointer to a
180 - A css_set contains a set of reference-counted pointers to
187 and in performance-critical code, whereas operations that require a
191 css_set->tasks.
193 - A cgroup hierarchy filesystem can be mounted for browsing and
196 - You can list all the tasks (by PID) attached to any cgroup.
199 into the rest of the kernel, none in performance-critical paths:
201 - in init/main.c, to initialize the root cgroups and initial
204 - in fork and exit, to attach and detach a task from its css_set.
209 comma-separated list of subsystems to mount as the filesystem mount
216 hierarchy, the mount will fail with -EBUSY. Otherwise, a new hierarchy
222 error-recovery issues.
225 child cgroups created below the top-level cgroup, that hierarchy
229 No new system calls are added for cgroups - all support for
239 - tasks: list of tasks (by PID) attached to that cgroup. This list
242 - cgroup.procs: list of thread group IDs in the cgroup. This list is
247 - notify_on_release flag: run the release agent on exit?
248 - release_agent: the path to use for release notifications (this file
260 a large system into nested, dynamically changeable, "soft-partitions".
264 on a system into related sets of tasks. A task may be re-attached to
269 css_set pointer - if there's an already existing css_set with the
281 each css_set that references the cgroup, and sub-iterating over
289 ------------------------------------
305 ---------------------------------
312 --------------------------
317 1) mount -t tmpfs cgroup_root /sys/fs/cgroup
319 3) mount -t cgroup -ocpuset cpuset /sys/fs/cgroup/cpuset
331 mount -t tmpfs cgroup_root /sys/fs/cgroup
333 mount -t cgroup cpuset -ocpuset /sys/fs/cgroup/cpuset
337 /bin/echo 2-3 > cpuset.cpus
349 ---------------
356 # mount -t cgroup xxx /sys/fs/cgroup
371 # mount -t tmpfs cgroup_root /sys/fs/cgroup
377 # mount -t cgroup -o cpuset,memory hier1 /sys/fs/cgroup/rg1
388 # mount -t cgroup -o cpuset,release_agent="/sbin/cpuset_release_agent" \
421 (plus whatever files added by the attached subsystems)
437 has processes attached, or is held alive by other subsystem-specific
441 -----------------------
462 attached to the cgroup. Writing 0 to cgroup.procs moves all tasks
474 --------------------------------
478 mounting a pre-existing hierarchy, in order to refer to it by name
482 The name should match [\w.-]+
497 ------------
506 - subsys_id: a unique array index for the subsystem, indicating which
507 entry in cgroup->subsys[] this subsystem should be managing.
509 - name: should be initialized to a unique subsystem name. Should be
512 - early_init: indicate if the subsystem needs early initialization
520 -------------------
534 - while holding cgroup_mutex
535 - while holding the task's alloc_lock (via task_lock())
536 - inside an rcu_read_lock() section via rcu_dereference()
539 -----------------
543 - add an entry in linux/cgroup_subsys.h
544 - define a cgroup_subsys object called <name>_cgrp_subsys
548 be successful no-ops.
558 larger subsystem-specific object), which will be initialized by the
570 subsystem may choose to fail creation by returning -errno. This
582 cgroup removal will proceed to the next step - css_free(). After this
590 is completely unused; @cgrp->parent is still valid. (Note - can also
591 be called for a newly-created cgroup if an error occurs after this
599 @tset contains the tasks to be attached and is guaranteed to have at
603 - it's guaranteed that all are from the same thread group
604 - @tset contains all tasks from the thread group whether or not
605 they're switching cgroups
606 - the first task is the leader
633 A subsystem whose can_attach() has some side-effects should provide this
641 Called after the task has been attached to the cgroup, to allow any
642 post-attachment activity that requires memory allocations or blocking.
662 the default hierarchy (which never has sub-cgroups) and a hierarchy
663 that is being created/destroyed (and hence has no sub-cgroups).
671 - Trusted (XATTR_TRUSTED)
672 - Security (XATTR_SECURITY)
695 Q: When I attach processes, only the first of the line gets really attached !