{
    "mode": "man",
    "parameter": "prlimit",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/prlimit/1/json",
    "generated": "2026-05-30T05:09:59Z",
    "synopsis": "prlimit [options] [--resource[=limits]] [--pid PID]\nprlimit [options] [--resource[=limits]] command [argument...]",
    "sections": {
        "NAME": {
            "content": "prlimit - get and set process resource limits\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "prlimit [options] [--resource[=limits]] [--pid PID]\n\nprlimit [options] [--resource[=limits]] command [argument...]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Given a process ID and one or more resources, prlimit tries to retrieve and/or modify the\nlimits.\n\nWhen command is given, prlimit will run this command with the given arguments.\n\nThe limits parameter is composed of a soft and a hard value, separated by a colon (:), in\norder to modify the existing values. If no limits are given, prlimit will display the current\nvalues. If one of the values is not given, then the existing one will be used. To specify the\nunlimited or infinity limit (RLIMINFINITY), the -1 or 'unlimited' string can be passed.\n\nBecause of the nature of limits, the soft limit must be lower or equal to the high limit\n(also called the ceiling). To see all available resource limits, refer to the RESOURCE\nOPTIONS section.\n\n•   soft:hard Specify both limits.\n\n•   soft: Specify only the soft limit.\n\n•   :hard Specify only the hard limit.\n\n•   value Specify both limits to the same value.\n",
            "subsections": []
        },
        "GENERAL OPTIONS": {
            "content": "",
            "subsections": [
                {
                    "name": "-h, --help",
                    "content": "Display help text and exit.\n",
                    "flag": "-h",
                    "long": "--help"
                },
                {
                    "name": "--noheadings",
                    "content": "Do not print a header line.\n",
                    "long": "--noheadings"
                },
                {
                    "name": "-o, --output",
                    "content": "Define the output columns to use. If no output arrangement is specified, then a default\nset is used. Use --help to get a list of all supported columns.\n",
                    "flag": "-o",
                    "long": "--output"
                },
                {
                    "name": "-p, --pid",
                    "content": "Specify the process id; if none is given, the running process will be used.\n",
                    "flag": "-p",
                    "long": "--pid"
                },
                {
                    "name": "--raw",
                    "content": "Use the raw output format.\n",
                    "long": "--raw"
                },
                {
                    "name": "--verbose",
                    "content": "Verbose mode.\n",
                    "long": "--verbose"
                },
                {
                    "name": "-V, --version",
                    "content": "Display version information and exit.\n",
                    "flag": "-V",
                    "long": "--version"
                }
            ]
        },
        "RESOURCE OPTIONS": {
            "content": "",
            "subsections": [
                {
                    "name": "-c, --core",
                    "content": "Maximum size of a core file.\n",
                    "flag": "-c",
                    "long": "--core"
                },
                {
                    "name": "-d, --data",
                    "content": "Maximum data size.\n",
                    "flag": "-d",
                    "long": "--data"
                },
                {
                    "name": "-e, --nice",
                    "content": "Maximum nice priority allowed to raise.\n",
                    "flag": "-e",
                    "long": "--nice"
                },
                {
                    "name": "-f, --fsize",
                    "content": "Maximum file size.\n",
                    "flag": "-f",
                    "long": "--fsize"
                },
                {
                    "name": "-i, --sigpending",
                    "content": "Maximum number of pending signals.\n",
                    "flag": "-i",
                    "long": "--sigpending"
                },
                {
                    "name": "-l, --memlock",
                    "content": "Maximum locked-in-memory address space.\n",
                    "flag": "-l",
                    "long": "--memlock"
                },
                {
                    "name": "-m, --rss",
                    "content": "Maximum Resident Set Size (RSS).\n",
                    "flag": "-m",
                    "long": "--rss"
                },
                {
                    "name": "-n, --nofile",
                    "content": "Maximum number of open files.\n",
                    "flag": "-n",
                    "long": "--nofile"
                },
                {
                    "name": "-q, --msgqueue",
                    "content": "Maximum number of bytes in POSIX message queues.\n",
                    "flag": "-q",
                    "long": "--msgqueue"
                },
                {
                    "name": "-r, --rtprio",
                    "content": "Maximum real-time priority.\n",
                    "flag": "-r",
                    "long": "--rtprio"
                },
                {
                    "name": "-s, --stack",
                    "content": "Maximum size of the stack.\n",
                    "flag": "-s",
                    "long": "--stack"
                },
                {
                    "name": "-t, --cpu",
                    "content": "CPU time, in seconds.\n",
                    "flag": "-t",
                    "long": "--cpu"
                },
                {
                    "name": "-u, --nproc",
                    "content": "Maximum number of processes.\n",
                    "flag": "-u",
                    "long": "--nproc"
                },
                {
                    "name": "-v, --as",
                    "content": "Address space limit.\n",
                    "flag": "-v",
                    "long": "--as"
                },
                {
                    "name": "-x, --locks",
                    "content": "Maximum number of file locks held.\n",
                    "flag": "-x",
                    "long": "--locks"
                },
                {
                    "name": "-y, --rttime",
                    "content": "Timeout for real-time tasks.\n",
                    "flag": "-y",
                    "long": "--rttime"
                }
            ]
        },
        "NOTES": {
            "content": "The prlimit system call is supported since Linux 2.6.36, older kernels will break this\nprogram.\n",
            "subsections": []
        },
        "EXAMPLES": {
            "content": "",
            "subsections": [
                {
                    "name": "prlimit --pid 13134",
                    "content": "Display limit values for all current resources.\n"
                },
                {
                    "name": "prlimit --pid 13134 --rss --nofile=1024:4095",
                    "content": "Display the limits of the RSS, and set the soft and hard limits for the number of open\nfiles to 1024 and 4095, respectively.\n"
                },
                {
                    "name": "prlimit --pid 13134 --nproc=512:",
                    "content": "Modify only the soft limit for the number of processes.\n"
                },
                {
                    "name": "prlimit --pid $$ --nproc=unlimited",
                    "content": "Set for the current process both the soft and ceiling values for the number of processes\nto unlimited.\n"
                },
                {
                    "name": "prlimit --cpu=10 sort -u hugefile",
                    "content": "Set both the soft and hard CPU time limit to ten seconds and run 'sort'.\n"
                }
            ]
        },
        "AUTHORS": {
            "content": "Davidlohr Bueso <dave@gnu.org> - In memory of Dennis M. Ritchie.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "ulimit(1p), prlimit(2)\n",
            "subsections": []
        },
        "REPORTING BUGS": {
            "content": "For bug reports, use the issue tracker at https://github.com/karelzak/util-linux/issues.\n",
            "subsections": []
        },
        "AVAILABILITY": {
            "content": "The prlimit command is part of the util-linux package which can be downloaded from Linux\nKernel Archive <https://www.kernel.org/pub/linux/utils/util-linux/>.\n\n\n\nutil-linux 2.37.2                            2021-07-20                                   PRLIMIT(1)",
            "subsections": []
        }
    },
    "summary": "prlimit - get and set process resource limits",
    "flags": [],
    "examples": [
        "Display limit values for all current resources.",
        "Display the limits of the RSS, and set the soft and hard limits for the number of open",
        "files to 1024 and 4095, respectively.",
        "Modify only the soft limit for the number of processes.",
        "Set for the current process both the soft and ceiling values for the number of processes",
        "to unlimited.",
        "Set both the soft and hard CPU time limit to ten seconds and run 'sort'."
    ],
    "see_also": [
        {
            "name": "ulimit",
            "section": "1p",
            "url": "https://www.chedong.com/phpMan.php/man/ulimit/1p/json"
        }
    ]
}