Bug 521134
| Summary: | Bash doesn't wait for backgrounded process if its PID is recycled | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 4 | Reporter: | Albert Hopkins <ahopkins> |
| Component: | bash | Assignee: | Roman Rakus <rrakus> |
| Status: | CLOSED ERRATA | QA Contact: | Petr Šplíchal <psplicha> |
| Severity: | high | Docs Contact: | |
| Priority: | urgent | ||
| Version: | 4.8 | CC: | fnadge, ohudlick, psplicha, rvokal, tao, tsmetana |
| Target Milestone: | rc | Keywords: | ZStream |
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | bash-3.0-23.el4 | Doc Type: | Bug Fix |
| Doc Text: |
Cause:
Backgrounded process PID is the same as the previous backgrounded process PID.
Consequence:
Bash doesn't wait for backgrounded process.
Fix:
Force bash to forgot last backgrounded process PID.
Result:
Bash waits for backgrounded process.
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2011-02-16 14:30:03 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 531235 | ||
It's fixed in bash-3.0-23.el4 Please be so kind and add a few key words to the technical note of this bugzilla entry using the following structure: Cause: Consequence: Fix: Result: For more details on CCFR texts, see: https://bugzilla.redhat.com/page.cgi?id=fields.html#cf_release_notes
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
New Contents:
Cause
Consequence:
Fix:
Result:
Technical note updated. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
Diffed Contents:
@@ -1,7 +1,11 @@
-Cause
+Cause:
+Backgrounded process PID is the same as the previous backgrounded process PID.
Consequence:
+Bash doesn't wait for backgrounded process.
Fix:
+Force bash to forgot last backgrounded process PID.
-Result:+Result:
+Bash waits for backgrounded process.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2011-0261.html |
The following condition occurs on RHEL4.8: [root@IT324086 ~]# uname -r ; rpm -q bash 2.6.9-89.0.9.EL bash-3.0-21.el4 [root@IT324086 ~]# echo 1000 > /proc/sys/kernel/pid_max # for example [root@IT324086 ~]# while true; do sleep 1d & done [1] 300 [2] 301 [3] 302 [4] 303 [5] 304 ... [696] 996 [697] 997 [698] 998 [699] 999 -bash: fork: Resource temporarily unavailable [root@IT324086 ~]# # kill some processes [root@IT324086 ~]# kill %1 [root@IT324086 ~]# kill %2 [1] Terminated sleep 1d [root@IT324086 ~]# man ps popen: Resource temporarily unavailable Attempt [/usr/bin/gunzip -c /usr/share/man/man1/ps.1.gz] to expand man page failed No manual entry for ps [2] Terminated sleep 1d [root@IT324086 ~]# ll [root@IT324086 ~]# ll total 88 -rw-r--r-- 1 root root 1068 Sep 3 15:03 anaconda-ks.cfg -rw-r--r-- 1 root root 65029 Sep 3 15:03 install.log -rw-r--r-- 1 root root 3062 Sep 3 15:03 install.log.syslog total 88 -rw-r--r-- 1 root root 1068 Sep 3 15:03 anaconda-ks.cfg -rw-r--r-- 1 root root 65029 Sep 3 15:03 install.log -rw-r--r-- 1 root root 3062 Sep 3 15:03 install.log.syslog This only happens for the current bash shell. Other bash shells running simultaneously respond fine.