bin/55346: /bin/sh eats memory and CPU infinitely

Eugene Grosbein eugen at
Thu Aug 7 08:20:08 PDT 2003

>Number:         55346
>Category:       bin
>Synopsis:       /bin/sh eats memory and CPU infinitely
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 07 08:20:05 PDT 2003
>Originator:     Eugene Grosbein
>Release:        FreeBSD 4.8-STABLE i386
JSC Svyaz-Service
System: FreeBSD 4.8-STABLE FreeBSD 4.8-STABLE #3: Wed Aug 6 21:50:36 KRAST 2003 eu at i386
	CPUTYPE=i686 and no other optimizations
	/bin/sh leaks memory and can eat all CPU cycles when
	it become very big.


	Test script is 15K in size so it comes gzipped
	and uuencoded. Yes, it is compressed very well.

begin 644
	Run it and watch how /bin/sh slowly increases
	its SIZE, RES, WCPU and CPU values.

	This is an exapmle. My real script grows upto 70Mb in size
	and eats all of idle Pentium-III 866Mhz cycles, it is
	machine-generated and runs 24x7x365. It's twice smaller
	than this test case.
	Now I have to restart it from time to time.


	Unknown for me.

Eugene Grosbein

More information about the freebsd-bugs mailing list