Summary: too much memory

From: Victor A. Holen (holen@xilinx.com)
Date: Thu Sep 03 1992 - 16:48:51 CDT


Thanks to all that responded. Since there was some interest, this is a short
summary.

I've asked:
> Is there a way to tell SunOS to pretend it has less physical memory
> then it has ? (Without yanking the chips).
======
From: barmar@think.com (Barry Margolin)

Write a program that mallocs 16Mb, calls plock(2) to lock its data segment
into physical memory memory, and then goes to sleep. That 16mb will be
unavailable to any other process, so you will effectively have reduced the
physical memory of the system.

Naturally, this program needs to run as root.

=====
 filipski@cs.buffalo.ed and andyfe@utoday.com
suggest writing a program that malloc's and than uses mlock(3)

=====

Mark.Monger@Eng.Sun.COM (Mark Monger) and barmar@think.com (Barry Margolin)
suggest patching physmem. (combined and edite response):

adb -w -k /vmunix /dev/mem
physmem/X
_physmem: xxxxx (reports physical memory in pages)
physmem?W 0x1000 (That's 0x1000 pages * 0x1000B/page = 16MB of memory)
^D

Rebooting is necessary.

You might want to save the kernel before you do this.
 or
Just patch physmem back to 0 for normal operation.
==============

-- 
 victor ....  ___  ._..  .  _.     holen@xilinx.com



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:06:49 CDT