From owner-freebsd-bugs Mon Jun 24 13:20:27 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id EB54237B407 for ; Mon, 24 Jun 2002 13:20:04 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g5OKK4Z06061; Mon, 24 Jun 2002 13:20:04 -0700 (PDT) (envelope-from gnats) Received: from nwww.freebsd.org (www.FreeBSD.org [216.136.204.117]) by hub.freebsd.org (Postfix) with ESMTP id 7BB1F37B400 for ; Mon, 24 Jun 2002 13:18:03 -0700 (PDT) Received: from www.freebsd.org (localhost [127.0.0.1]) by nwww.freebsd.org (8.12.2/8.12.2) with ESMTP id g5OKI3hG016439 for ; Mon, 24 Jun 2002 13:18:03 -0700 (PDT) (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.12.2/8.12.2/Submit) id g5OKI35o016438; Mon, 24 Jun 2002 13:18:03 -0700 (PDT) Message-Id: <200206242018.g5OKI35o016438@www.freebsd.org> Date: Mon, 24 Jun 2002 13:18:03 -0700 (PDT) From: Greg Quinlan To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-1.0 Subject: i386/39802: iBCS2 emulation fork process core dumps Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 39802 >Category: i386 >Synopsis: iBCS2 emulation fork process core dumps >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Jun 24 13:20:04 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Greg Quinlan >Release: 4.6-Stable >Organization: >Environment: 4.6-Stable >Description: Using iBCS2 emulation ONLY with IBCS2 Binaries ONLY; Any iBCS2 (COFF/SCO) binary which forks a process (child process) will get the next PID (ranging from X to 99999, see /sys/sys/proc.h), but most iBCS2 binaries have an upper PID limit of around 32700 (short int). So after the PID count exceeds this value, the program will crash (core dump). It may give an error of 'can't fork process' or similar. >How-To-Repeat: The problem will not reproduce itself until the current PID reaches around 32700 which may not happen for some time after a boot or reboot. Wait for the PID number to exceed 'short int', and for an iBCS2 program to fork a child process. >Fix: - Modify the /sys/sys/proc.h change PID_MAX from 99999 to a safe value of 32759, and also change NO_PID from 100000 to a safe value of 32760. - Remake the kernel & reboot. This should be included as a WARNING in the documentation for IBCS2 emulation. Or modified automatically if the option for iBCS2 is included in the /etc/rc.conf file. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message