summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorGiampaolo Rodola <g.rodola@gmail.com>2020-10-23 19:57:17 +0200
committerGitHub <noreply@github.com>2020-10-23 19:57:17 +0200
commit89ae354ab7704db69a3f6c880234d21719558511 (patch)
treeb8a87ef018d4f0e7cef48111bfe001390224ba8c /scripts
parentba083a0eea87331b67b57c3c83e8cc53faa12b10 (diff)
downloadpsutil-89ae354ab7704db69a3f6c880234d21719558511.tar.gz
[FreeBSD] process resource limits (#1859) (#809)
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/procinfo.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/procinfo.py b/scripts/procinfo.py
index f0605386..8eea3377 100755
--- a/scripts/procinfo.py
+++ b/scripts/procinfo.py
@@ -108,11 +108,14 @@ RLIMITS_MAP = {
"RLIMIT_NICE": "nice",
"RLIMIT_NOFILE": "openfiles",
"RLIMIT_NPROC": "maxprocesses",
+ "RLIMIT_NPTS": "pseudoterms",
"RLIMIT_RSS": "rss",
"RLIMIT_RTPRIO": "realtimeprio",
"RLIMIT_RTTIME": "rtimesched",
+ "RLIMIT_SBSIZE": "sockbufsize",
"RLIMIT_SIGPENDING": "sigspending",
"RLIMIT_STACK": "stack",
+ "RLIMIT_SWAP": "swapuse",
}
@@ -317,7 +320,7 @@ def run(pid, verbose=False):
def main(argv=None):
parser = argparse.ArgumentParser(
description="print information about a process")
- parser.add_argument("pid", type=int, help="process pid")
+ parser.add_argument("pid", type=int, help="process pid", nargs='?')
parser.add_argument('--verbose', '-v', action='store_true',
help="print more info")
args = parser.parse_args()