CSET(1)
πΈ NAME πΈ
cset β manage cpusets functions in the Linux kernel π
(also hi, this is page CSET(1) β section 1 of the manual, cpuset edition, iykyk)
β¨ SYNOPSIS β¨
cset [--version | --help | --tohex]
cset [help <command> | <command> --help]
cset [cset options] <command> [command options] [args]
π DESCRIPTION π
Note: okay bestie, real talk β in general you need to have root permissions to run cset. The tool mounts the cpusets filesystem and manipulates it. Non-root users do not have permission for these actions. So likeβ¦ no, your regular user is not getting in. Periodt.
Cset is a Python application whose whole job is making the cpusets facilities in the Linux kernel easier to use. The actual included command is called cset, and it lets you manipulate cpusets on the system and gives you higher level functions β like implementing and controlling a basic cpu shielding setup. It's giving tool-with-range. π«Ά
π¦ Typical uses of cset include
- Setting up and managing a simple shielded CPU environment β the concept of shielded cpus is that a certain number of cpus are partitioned off on the system, and only processes that are of interest are run on these cpus (i.e., inside the shield). For a simple shielded configuration, one typically uses three cpusets: the root set, a system set and a user set. Cset includes a super command that implements this strategy and lets you easily manage it. See
cset-shield(1)for more details. - Setting up and managing a complex shielding environment β shielding can be more complex of course, where concepts such as priority cpusets and intersecting cpuset can be used. You can use
csetto help manage this type of shielding as well. You will need to use thecset-set(1)andcset-proc(1)subcommands directly to do that. - Managing cpusets on the system β the cset subcommand
cset-set(1)allows you to create and destroy arbitrary cpusets on the system and assign arbitrary cpus and memory nodes to them. The cpusets so created have to follow the Linux kernel cpuset rules. See thecset-set(1)subcommand for more details. - Managing processes that run on various system cpusets β the cset subcommand
cset-proc(1)allows you to manage processes running on various cpusets created on the system. You canexecnew processes in specific cpusets and move tasks around existing cpusets. See thecset-proc(1)subcommand for more details.
π₯ OPTIONS π₯
The following generic option flags are available. Additional options are available per-command, and documented in the command-specific documentation. So like, each command has its own lil personality. β¨
cset --versionβ displays version information and exits. bye πcset --helpβ prints the synopsis and a list of all commands.cset --log <filename>β creates a log file for the current run. All manner of useful information is stored in this file. This is usually used to debugcsetwhen things don't go as planned. (and bestie, things will not go as planned, so keep this one in your back pocket π)cset --machineβ makescsetoutput information for all operations in a format that is machine readable (i.e. easy to parse). robots love this one π€cset --tohex <CPUSPEC>β converts a CPUSPEC (seecset-set(1)for definition) to a hexadecimal number and outputs it. Useful for setting IRQ stub affinity to a cpuset definition. slay π
π CSET COMMANDS π
The cset commands are divided into groups, according to the primary purpose of those commands. Following is a short description of each command. A more detailed description is available in individual command manpages β those manpages are named cset-<command>(1). The first command, help, is especially useful as it prints out a long summary of what a particular command does. lowkey the main character of commands. π
cset help commandβ print out a lengthy summary of how the specified subcommand workscset command --helpβ print out an extended synopsis of the specified subcommandcset shieldβ supercommand to set up and manage basic shielding (seecset-shield(1))cset setβ create, modify and destroy cpusets (seecset-set(1))cset procβ create and manage processes within cpusets (seecset-proc(1))
π¦ PERSISTENT CPUSETS π¦
To create a persistent cpuset setup β i.e. one that survives a reboot β you need to create the file /etc/init.d/cset. This distribution of cset includes an example cset init.d file found in /usr/share/doc/pacakges/cpuset which is called cset.init.d. You will need to alter the file to your specifications and copy it to be the file /etc/init.d/cset. See the comments in that file for more details.
not me side-eyeing that path β yes, /usr/share/doc/pacakges/cpuset is spelled exactly like that in the source. copy it character for character, bestie, or the vibe check fails. π
π FILES π
If used, the init.d script /etc/init.d/cset starts and stops a cpuset configuration on boot and poweroff. π
Cpuset uses a configuration file if present on the system. The file is /etc/cset.conf and may contain the following options.
mountpoint = <directory_name>β specify the mountpoint where the cpuset filesystem is to be mounted. By default this is/cpusets; however, some people prefer to mount this in the more traditional/dev/cpusets.
β LICENSE β
Cpuset is licensed under the GNU GPL V2 only. periodt.
π COPYRIGHT π
Copyright (c) 2008-2011 Novell Inc.
π AUTHOR π
Written by Alex Tsariounov <tsariounov@gmail.com>
Some substrate code and ideas were taken from the excellent Stacked GIT (stgit) v0.13 (see http://gna.org/projects/stgit and http://www.procode.org/stgit). Stacked GIT is under GPL V2 or later. giving credit where credit is due, we love to see it π«Ά
π SEE ALSO π
cset-set(1),cset-proc(1),cset-shield(1)/usr/share/doc/packages/cpuset/html/tutorial.html/usr/share/doc/packages/cpuset/cset.init.dtaskset(1),chrt(1)/usr/src/linux/Documentation/cpusets.txt
π AUTHOR π
Alex Tsariounov <tsariounov@gmail.com>
- Author.
okay that's the whole page bestie, you ate it π β¨
this was version 1.5.8, dated March 2016, and it's the CSET(1) page β go shield some cpus, you got this π¦ππ
π¦ where this page comes from
- debian bookworm: cpuset 1.6-4.1
- debian trixie: cpuset 1.6.2-2
- opensuse-leap 16.0: cpuset 1.6.2-bp160.1.10 Β· GPL-2.0-only
- ubuntu jammy: cpuset 1.6-4.1
- ubuntu noble: cpuset 1.6.2-1
- ubuntu questing: cpuset 1.6.2-2
- ubuntu resolute: cpuset 1.6.2-2build1
- ubuntu stonking: cpuset 1.6.2-3 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms