Thanks to all that responded. Since there was some interest, this is a short
> Is there a way to tell SunOS to pretend it has less physical memory
> then it has ? (Without yanking the chips).
From: firstname.lastname@example.org (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.
email@example.com and firstname.lastname@example.org
suggest writing a program that malloc's and than uses mlock(3)
Mark.Monger@Eng.Sun.COM (Mark Monger) and email@example.com (Barry Margolin)
suggest patching physmem. (combined and edite response):
adb -w -k /vmunix /dev/mem
_physmem: xxxxx (reports physical memory in pages)
physmem?W 0x1000 (That's 0x1000 pages * 0x1000B/page = 16MB of memory)
Rebooting is necessary.
You might want to save the kernel before you do this.
Just patch physmem back to 0 for normal operation.
-- victor .... ___ ._.. . _. firstname.lastname@example.org
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:06:49 CDT