Re: panic: vm_map_wire: lookup failed

From: John Hay <jhay_at_icomtek.csir.co.za>
Date: Thu, 16 Oct 2003 22:54:43 +0200
> 
> The latest development source of ntpd started to use setrlimit() before
> using mlockall(). This combination proves fatal on -current. The code
> in ntpd/ntpd.c looks like this:

Ok, I found an easier way to provoke the panic. Just compile the following
program like this:

cc -Wall -O -o vm -lcrypto vm.c

and run as root. The program itself does not use the crypto, but it is
needed to provoke the panic.

##################### vm.c ##########################
#include <stdio.h>
#include <sys/mman.h>

int
main(int argc, char **argv)
{
	/*
	 * lock the process into memory
	 */
	if (mlockall(MCL_CURRENT|MCL_FUTURE) < 0)
		perror("mlockall()");

	return 0;
}
#######################################################

John
-- 
John Hay -- John.Hay_at_icomtek.csir.co.za / jhay_at_FreeBSD.org
Received on Thu Oct 16 2003 - 11:54:49 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:25 UTC