Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 11 Mar 1999 16:29:34 +0100
From:      Marc Olzheim <marcolz@stack.nl>
To:        freebsd-stable@freebsd.org
Subject:   2.2.{6,7,8} freeze
Message-ID:  <19990311162934.A13991@stack.nl>

next in thread | raw e-mail | index | archive | help


Hi,

This probably has been noted before, but I couldn't find anything about it,
so...

When running two processes,, each one trying to eat up as much memory as
possible, the system deadlocks in the vm-routines. It seems as if the system
needs some memory to kill the largest process in the table and it can't
get it or something like that.

Anyone knows if this has been fixed in 3.* ?

The following prog does the job...

----------------------------------------------------------------------

#include	<stdio.h>
#include	<stdlib.h>
#include	<unistd.h>

int
main(int argc, char *argv[])
{
	int		n = 16 * 1024 * 1024;
	void		*temp;
	int		i;

	if (argc != 2)
	{
		fprintf(stderr, "Usage: %s <num>\n", argv[0]);
		return(1);
	}

	for (i = atoi(argv[1]) - 1; i > 0; i--)
		fork();

	while (n)
	{
		temp = calloc(n, 1);
		if (temp)
			n <<= 1;
		else
			n>>= 1;
	}

	sleep(1000);

	return(0);
}


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990311162934.A13991>