From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <96075320706604.tru64-unix-managers.marc@archive.invalid> From: haymanR () icefog ! uacn ! alaska ! edu Date: Fri, 23 Jun 1995 15:46:37 +0000 To: tru64-unix-managers Subject: SUMMARY: CHILD_MAX & osf/1 v3.0 X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=96075320706604 CHILD_MAX is different under v3.0 and v3.2, and here's what I found out: From: Jon Reeves |>I just looked at the logs: it was changed in base level 2 of V3.2 (last |>Sept. 12). If you need the actual value in V3.0, do what sysconf now |>does: call getsysinfo(GSI_MAX_UPROCS); if it fails, then use CHILD_MAX. |> |>The value of _POSIX_CHILD_MAX is fixed by the POSIX standard at a |>constant 6, but you probably already knew that. From: "Jeffrey C. Ollie" 1st response: |>Put: |> |>proc: |> max-proc-per-user = 256 |> |>in /etc/sysconfigtab and reboot. 2nd response: |>Have you actually tried forking off more than CHILD_MAX processes? Since the |>man page says that CHILD_MAX is a *minimum*, you should be able to fork off |>at least that many processes (possibly more), or at least until you hit the |>max-proc-per-user limit. |> |>With this test program: |> |>#include |>#include |>#include |>#include |> |>int main() |>{ |> int count; |> pid_t pid; |> |> printf("%d\n", sysconf(_SC_CHILD_MAX)) |> |> count = 0; |> while(1) |> { |> pid = fork(); |> if (pid == -1) |> { |> printf("%d\n", count); |> exit(0); |> } |> if (pid == 0) |> { |> sleep(5); |> exit(0); |> } |> count = count + 1; |> } |>} |> |>and max-proc-per-user = 128, I was able to fork off 125 other processes (2 |>shells and the test program account for the other three) when sysconf |>reported that _SC_CHILD_MAX was 64. This is on an OSF/1 3.0 system. |> |>When tried on an OSF/1 3.2A system with max-proc-per-user=64, I was only able |>to fork off 60 processes (2 shells, nn and the test program make 64). However |>_SC_CHILD_MAX reported 1024. It would seem here that the value of the |>max-proc-per-user parameter is more important than the value of |>_SC_CHILD_MAX. Keith Lewis |> Create a file called /etc/proc.stanza containing: |> |>proc: |> max-proc-per-user = 256 |> |> Then type `sysconfigdb -f /etc/proc.stanza proc' |> |> Then reboot. My original posting was: > Greetings - > > All of my attempts to raise CHILD_MAX (visible via getconf CHILD_MAX) from > 64 have been unsuccessful. I've modified altering the 64 > and making it 256, I've modified param.c, I've raised maxuprc in > /sys/conf/, etc... after each modification attempt I've rebuilt > the kernel and moved the new kernel to / and rebooted. Still > getconf CHILD_MAX (and _POSIX_CHILD_MAX) remain unchanged at 64 and 6 > respectively. Any other ideas? Is this a v3.0 limitation? > > TIA Summary pending responses. Randy M. Hayman haymanr@icefog.alaska.edu