{
    "content": [
        {
            "type": "text",
            "text": "# cgcreate (man)\n\n## NAME\n\ncgcreate - create new cgroup(s)\n\n## SYNOPSIS\n\ncgcreate  [-h]  [-t  <tuid>:<tgid>] [-a <agid>:<auid>] [-f mode] [-d mode] [-s mode] -g <con‐\ntrollers>:<path> [-g ...]\n\n## DESCRIPTION\n\nThe command creates new cgroup(s) defined by the options -g.\n\n## TLDR\n\n> Create cgroups, used to limit, measure, and control resources used by processes.\n\n- Create a new [g]roup:\n  `cgcreate -g {{group_type}}:{{group_name}}`\n- Create a new [g]roup with multiple cgroup types:\n  `cgcreate -g {{group_type1}},{{group_type2}}:{{group_name}}`\n- Create a subgroup:\n  `mkdir /sys/fs/cgroup/{{group_type}}/{{group_name}}/{{subgroup_name}}`\n\n*Source: tldr-pages*\n\n## Sections\n\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION** (7 subsections)\n- **ENVIRONMENT VARIABLES**\n- **EXAMPLES**\n- **SEE ALSO**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "cgcreate",
        "section": "",
        "mode": "man",
        "summary": "cgcreate - create new cgroup(s)",
        "synopsis": "cgcreate  [-h]  [-t  <tuid>:<tgid>] [-a <agid>:<auid>] [-f mode] [-d mode] [-s mode] -g <con‐\ntrollers>:<path> [-g ...]",
        "tldr_summary": "Create cgroups, used to limit, measure, and control resources used by processes.",
        "tldr_examples": [
            {
                "description": "Create a new [g]roup",
                "command": "cgcreate -g {{group_type}}:{{group_name}}"
            },
            {
                "description": "Create a new [g]roup with multiple cgroup types",
                "command": "cgcreate -g {{group_type1}},{{group_type2}}:{{group_name}}"
            },
            {
                "description": "Create a subgroup",
                "command": "mkdir /sys/fs/cgroup/{{group_type}}/{{group_name}}/{{subgroup_name}}"
            }
        ],
        "tldr_source": "official",
        "flags": [
            {
                "flag": "-a",
                "long": null,
                "arg": null,
                "description": "defines the name of the user and the group which own the rest of the defined control group’s files. These users are allowed to set subsystem parameters and create sub‐ groups. The default value is the same as has the parent cgroup."
            },
            {
                "flag": "-d",
                "long": "--dperm",
                "arg": "mode",
                "description": "sets the permissions of a control groups directory. The permissions needs to be spec‐ ified as octal numbers e.g. -d 775."
            },
            {
                "flag": "-f",
                "long": "--fperm",
                "arg": "mode",
                "description": "sets the permissions of the control groups parameters. The permissions needs to be specified as octal numbers e.g. -f 775. The value is not used as given because the current owner's permissions are used as an umask (so 777 will set group and others permissions to the owners permissions)."
            },
            {
                "flag": "-g",
                "long": null,
                "arg": null,
                "description": "defines control groups to be added. controllers is a list of controllers. Character \"*\" can be used as a shortcut for \"all mounted controllers\". path is the relative path to control groups in the given controllers list. This option can be specified multiple times."
            },
            {
                "flag": "-h",
                "long": "--help",
                "arg": null,
                "description": "display this help and exit"
            },
            {
                "flag": "-s",
                "long": "--tperm",
                "arg": "mode",
                "description": "sets the permissions of the control group tasks file. The permissions needs to be specified as octal numbers e.g. -s 775. The value is not used as given because the current owner's permissions are used as an umask (so 777 will set group and others permissions to the owners permissions)."
            },
            {
                "flag": "-t",
                "long": null,
                "arg": null,
                "description": "defines the name of the user and the group, which owns tasks file of the defined con‐ trol group. I.e. this user and members of this group have write access to the file. The default value is the same as has the parent cgroup."
            }
        ],
        "examples": [
            "cgcreate -g *:student devices:teacher",
            "create control group student in all  mounted  hierarchies  and  create  control  group",
            "teacher in hierarchy containing controller devices."
        ],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 3,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 3,
                "subsections": [
                    {
                        "name": "-a <agid>:<auid>",
                        "lines": 5,
                        "flag": "-a"
                    },
                    {
                        "name": "-d, --dperm=mode",
                        "lines": 4,
                        "flag": "-d",
                        "long": "--dperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-f, --fperm=mode",
                        "lines": 6,
                        "flag": "-f",
                        "long": "--fperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-g <controllers>:<path>",
                        "lines": 6,
                        "flag": "-g"
                    },
                    {
                        "name": "-h, --help",
                        "lines": 3,
                        "flag": "-h",
                        "long": "--help"
                    },
                    {
                        "name": "-s, --tperm=mode",
                        "lines": 6,
                        "flag": "-s",
                        "long": "--tperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-t <tuid>:<tgid>",
                        "lines": 5,
                        "flag": "-t"
                    }
                ]
            },
            {
                "name": "ENVIRONMENT VARIABLES",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "EXAMPLES",
                "lines": 8,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 5,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "cgcreate - create new cgroup(s)\n\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "cgcreate  [-h]  [-t  <tuid>:<tgid>] [-a <agid>:<auid>] [-f mode] [-d mode] [-s mode] -g <con‐\ntrollers>:<path> [-g ...]\n\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "The command creates new cgroup(s) defined by the options -g.\n\n",
                "subsections": [
                    {
                        "name": "-a <agid>:<auid>",
                        "content": "defines the name of the user and the group which own the rest of the  defined  control\ngroup’s  files.  These  users  are allowed to set subsystem parameters and create sub‐\ngroups.  The default value is the same as has the parent cgroup.\n\n",
                        "flag": "-a"
                    },
                    {
                        "name": "-d, --dperm=mode",
                        "content": "sets the permissions of a control groups directory.  The permissions needs to be spec‐\nified as octal numbers e.g.  -d 775.\n\n",
                        "flag": "-d",
                        "long": "--dperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-f, --fperm=mode",
                        "content": "sets  the  permissions  of the control groups parameters.  The permissions needs to be\nspecified as octal numbers e.g.  -f 775.  The value is not used as given  because  the\ncurrent  owner's  permissions  are  used as an umask (so 777 will set group and others\npermissions to the owners permissions).\n\n",
                        "flag": "-f",
                        "long": "--fperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-g <controllers>:<path>",
                        "content": "defines control groups to be added.  controllers is a list of  controllers.  Character\n\"*\"  can  be  used  as a shortcut for \"all mounted controllers\".  path is the relative\npath to control groups in the given controllers list. This  option  can  be  specified\nmultiple times.\n\n",
                        "flag": "-g"
                    },
                    {
                        "name": "-h, --help",
                        "content": "display this help and exit\n\n",
                        "flag": "-h",
                        "long": "--help"
                    },
                    {
                        "name": "-s, --tperm=mode",
                        "content": "sets  the  permissions  of  the control group tasks file.  The permissions needs to be\nspecified as octal numbers e.g.  -s 775.  The value is not used as given  because  the\ncurrent  owner's  permissions  are  used as an umask (so 777 will set group and others\npermissions to the owners permissions).\n\n",
                        "flag": "-s",
                        "long": "--tperm",
                        "arg": "mode"
                    },
                    {
                        "name": "-t <tuid>:<tgid>",
                        "content": "defines the name of the user and the group, which owns tasks file of the defined  con‐\ntrol  group.  I.e.  this user and members of this group have write access to the file.\nThe default value is the same as has the parent cgroup.\n\n",
                        "flag": "-t"
                    }
                ]
            },
            "ENVIRONMENT VARIABLES": {
                "content": "CGROUPLOGLEVEL\ncontrols verbosity of the tool. Allowed values are DEBUG, INFO, WARNING or ERROR.\n\n",
                "subsections": []
            },
            "EXAMPLES": {
                "content": "cgcreate -g *:student devices:teacher\ncreate control group student in all  mounted  hierarchies  and  create  control  group\nteacher in hierarchy containing controller devices.\n\n\n\n\n",
                "subsections": []
            },
            "SEE ALSO": {
                "content": "cgrules.conf (5) cgexec (1) cgclassify (1)\n\n\n\nLinux                                        2009-03-15                                  CGCREATE(1)",
                "subsections": []
            }
        }
    }
}