Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src Clean-up resources (sys/sys/resource.h) usage
details: https://anonhg.NetBSD.org/src/rev/09eadd2857df
branches: trunk
changeset: 339298:09eadd2857df
user: kamil <kamil%NetBSD.org@localhost>
date: Sat Jul 11 09:21:22 2015 +0000
description:
Clean-up resources (sys/sys/resource.h) usage
Add vmemoryuse to login_cap(3)
Document vmemoryuse in login.conf(5)
Document proc.pid.rlimit.vmemoryuse and proc.pid.rlimit.maxlwp in sysctl(7)
Document SBSIZE, AS, VMEM and NTHR in share/doc/psd/05.sysman/1.6.t
Reviewed by <riastradh>
Approved by <pgoyette>
Tested by Dominik Bialy
Closes PR xsrc/49912
diffstat:
lib/libutil/login_cap.c | 5 +++--
share/doc/psd/05.sysman/1.6.t | 6 +++++-
share/man/man5/login.conf.5 | 6 +++++-
share/man/man7/sysctl.7 | 8 +++++++-
4 files changed, 20 insertions(+), 5 deletions(-)
diffs (88 lines):
diff -r 391a988e1ab0 -r 09eadd2857df lib/libutil/login_cap.c
--- a/lib/libutil/login_cap.c Sat Jul 11 07:43:32 2015 +0000
+++ b/lib/libutil/login_cap.c Sat Jul 11 09:21:22 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: login_cap.c,v 1.31 2013/06/29 04:52:55 yamt Exp $ */
+/* $NetBSD: login_cap.c,v 1.32 2015/07/11 09:21:22 kamil Exp $ */
/*-
* Copyright (c) 1995,1997 Berkeley Software Design, Inc. All rights reserved.
@@ -36,7 +36,7 @@
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: login_cap.c,v 1.31 2013/06/29 04:52:55 yamt Exp $");
+__RCSID("$NetBSD: login_cap.c,v 1.32 2015/07/11 09:21:22 kamil Exp $");
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
@@ -424,6 +424,7 @@
{ RLIMIT_NOFILE, R_CNUMB, "openfiles", },
{ RLIMIT_CORE, R_CSIZE, "coredumpsize", },
{ RLIMIT_SBSIZE, R_CSIZE, "sbsize", },
+ { RLIMIT_AS, R_CSIZE, "vmemoryuse", },
{ -1, 0, 0 }
};
diff -r 391a988e1ab0 -r 09eadd2857df share/doc/psd/05.sysman/1.6.t
--- a/share/doc/psd/05.sysman/1.6.t Sat Jul 11 07:43:32 2015 +0000
+++ b/share/doc/psd/05.sysman/1.6.t Sat Jul 11 09:21:22 2015 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: 1.6.t,v 1.5 2013/10/06 05:45:19 dholland Exp $
+.\" $NetBSD: 1.6.t,v 1.6 2015/07/11 09:21:23 kamil Exp $
.\"
.\" Copyright (c) 1983, 1993, 1994
.\" The Regents of the University of California. All rights reserved.
@@ -133,6 +133,10 @@
RLIMIT_MEMLOCK /* locked-in-memory address space */
RLIMIT_NPROC /* number of processes */
RLIMIT_NOFILE /* number of open files */
+RLIMIT_SBSIZE /* maximum size of all socket buffers */
+RLIMIT_AS /* virtual process size (inclusive of mmap) */
+RLIMIT_VMEM /* alias of RLIMIT_AS */
+RLIMIT_NTHR /* number of threads */
.TE
.DE
.ne 1i
diff -r 391a988e1ab0 -r 09eadd2857df share/man/man5/login.conf.5
--- a/share/man/man5/login.conf.5 Sat Jul 11 07:43:32 2015 +0000
+++ b/share/man/man5/login.conf.5 Sat Jul 11 09:21:22 2015 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: login.conf.5,v 1.28 2013/06/29 08:14:31 wiz Exp $
+.\" $NetBSD: login.conf.5,v 1.29 2015/07/11 09:21:23 kamil Exp $
.\"
.\" Copyright (c) 1995,1996,1997 Berkeley Software Design, Inc.
.\" All rights reserved.
@@ -271,6 +271,10 @@
.Xr umask 2 .
.\"
.sp
+.It Sy vmemoryuse Ta size Ta "" Ta
+Maximum virtual address space size in bytes.
+.\"
+.sp
.It Sy welcome Ta file Ta Li /etc/motd Ta
File containing welcome message.
.Xr login 1
diff -r 391a988e1ab0 -r 09eadd2857df share/man/man7/sysctl.7
--- a/share/man/man7/sysctl.7 Sat Jul 11 07:43:32 2015 +0000
+++ b/share/man/man7/sysctl.7 Sat Jul 11 09:21:22 2015 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: sysctl.7,v 1.87 2015/05/27 07:52:02 matt Exp $
+.\" $NetBSD: sysctl.7,v 1.88 2015/07/11 09:21:23 kamil Exp $
.\"
.\" Copyright (c) 1993
.\" The Regents of the University of California. All rights reserved.
@@ -2049,6 +2049,12 @@
and
.Dv SO_SNDBUF
options.
+.It Li proc.pid.rlimit.vmemoryuse ( PROC_PID_LIMIT_AS )
+The maximum size (in bytes) which a process can obtain.
+.It Li proc.pid.rlimit.maxlwp ( PROC_PID_LIMIT_NTHR )
+The maximum number of threads that cen be created and running at one time in
+the process.
+The first thread of each process is not counted against this.
.El
.Pp
The fifth level name is one of
Home |
Main Index |
Thread Index |
Old Index