public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/1535] New: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit?
@ 2005-10-24 14:21 michael dot kerrisk at gmx dot net
  2005-12-23  6:11 ` [Bug libc/1535] " drepper at redhat dot com
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: michael dot kerrisk at gmx dot net @ 2005-10-24 14:21 UTC (permalink / raw)
  To: glibc-bugs

(On Linux/x86), sysconf(_SC_CHILD_MAX) always reports 999, regardless of the
current setting of the RLIMIT_NPROC soft resource limit.  Would it not make more
sense to return the current value of the RLIMIT_NPROC soft resource limit?

-- 
           Summary: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource
                    limit?
           Product: glibc
           Version: 2.3.4
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
        AssignedTo: drepper at redhat dot com
        ReportedBy: michael dot kerrisk at gmx dot net
                CC: glibc-bugs at sources dot redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=1535

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/1535] Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit?
  2005-10-24 14:21 [Bug libc/1535] New: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit? michael dot kerrisk at gmx dot net
@ 2005-12-23  6:11 ` drepper at redhat dot com
  2006-01-08  9:39 ` cvs-commit at gcc dot gnu dot org
  2006-01-08  9:44 ` roland at gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: drepper at redhat dot com @ 2005-12-23  6:11 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From drepper at redhat dot com  2005-12-23 06:11 -------
Tell this to the kernel people.  It's <linux/limits.h> which defines the value.
 It's wrong that 999 signals no limit, this is what -1 does.  Or even better, no
definition of the macro at all.  This macro is used in the solaris emulation
sysconf implementation and it returns the wrong value, too.  There is nothing
the userlevel code should do.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WONTFIX


http://sourceware.org/bugzilla/show_bug.cgi?id=1535

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/1535] Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit?
  2005-10-24 14:21 [Bug libc/1535] New: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit? michael dot kerrisk at gmx dot net
  2005-12-23  6:11 ` [Bug libc/1535] " drepper at redhat dot com
@ 2006-01-08  9:39 ` cvs-commit at gcc dot gnu dot org
  2006-01-08  9:44 ` roland at gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2006-01-08  9:39 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2006-01-08 09:39 -------
Subject: Bug 1535

CVSROOT:	/cvs/glibc
Module name:	libc
Changes by:	roland@sources.redhat.com	2006-01-08 09:39:16

Modified files:
	sysdeps/posix  : sysconf.c 
	posix          : Makefile 
	include/sys    : sysinfo.h 
Added files:
	posix          : get_child_max.c 
	sysdeps/unix   : get_child_max.c 

Log message:
	2006-01-08  Roland McGrath  <roland@redhat.com>
	
	[BZ #1535]
	* sysdeps/unix/get_child_max.c: New file.
	* posix/get_child_max.c: New file.
	* posix/Makefile (routines): Add it.
	* include/sys/sysinfo.h (__get_child_max): Declare it.
	* sysdeps/posix/sysconf.c (__sysconf) [! CHILD_MAX]: Use it.

Patches:
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/sysdeps/posix/sysconf.c.diff?cvsroot=glibc&r1=1.40&r2=1.41
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/posix/get_child_max.c.diff?cvsroot=glibc&r1=NONE&r2=1.1
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/posix/Makefile.diff?cvsroot=glibc&r1=1.187&r2=1.188
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/sysdeps/unix/get_child_max.c.diff?cvsroot=glibc&r1=NONE&r2=1.1
http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/include/sys/sysinfo.h.diff?cvsroot=glibc&r1=1.4&r2=1.5



-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=1535

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/1535] Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit?
  2005-10-24 14:21 [Bug libc/1535] New: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit? michael dot kerrisk at gmx dot net
  2005-12-23  6:11 ` [Bug libc/1535] " drepper at redhat dot com
  2006-01-08  9:39 ` cvs-commit at gcc dot gnu dot org
@ 2006-01-08  9:44 ` roland at gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: roland at gnu dot org @ 2006-01-08  9:44 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From roland at gnu dot org  2006-01-08 09:44 -------
I've committed code on the trunk that will use the RLIMIT_NPROC value in sysconf
when CHILD_MAX is not defined at compile time.  This has no effect until the
kernel header is changed to remove CHILD_MAX, and then a glibc compiled against
thew new kernel headers will yield the dynamic value, matching applications
compiled against those headers that expect a runtime-variable value.
Because CHILD_MAX is specified as a runtime invariant value, we are not at
liberty to make sysconf return a different value from the CHILD_MAX constant as
long as one is defined.  This requirement will be violated when there is skew
between built applications using an old CHILD_MAX value from old kernel headers,
and a newer libc.so built against new kernel headers.  But that is the same
violation that occurs whenever libc.so is built against new kernel headers that
have changed the constant value, just the same as removing the constant.

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=1535

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-01-08  9:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-10-24 14:21 [Bug libc/1535] New: Make _SC_CHILD_MAX retort RLIMIT_NPROC soft resource limit? michael dot kerrisk at gmx dot net
2005-12-23  6:11 ` [Bug libc/1535] " drepper at redhat dot com
2006-01-08  9:39 ` cvs-commit at gcc dot gnu dot org
2006-01-08  9:44 ` roland at gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).