* (no subject)
@ 1997-05-27 13:36 root
1999-04-07 15:09 ` none Eric W. Biederman
0 siblings, 1 reply; 2+ messages in thread
From: root @ 1997-05-27 13:36 UTC (permalink / raw)
To: linux-mm
I am leiyin, a software engineer in china, beijing. I am interested
in Linux memory management these day. Since I find an ordinary user
can easily occupy all the memory available. Though I don't think this is
a bug. I wonder whether I can control how much memory a user can occup
,including swap space, or not.
For example, this program occupy.c
compile: cc -o occupy occupy.c
#define BLOCK 100000
#define PGSIZE 4096
char *p[BLOCK];
main()
{
int i,j;
for(i=0;i<BLOCK;i++)
{
for(j=0;j<PGSIZE;j++)
p[i][j] = 0;
}
sleep(100000);
}
when I run occupy. My linux system with 32 RAM soon show
Out of Memory. And any other users cannot login and work normally.
Especially in AS400 OS/400 one can distribute a fixed size physical memory
(pool) for a subsystem. If Linux can do this( I mean a fixed size memory for
a user not subsystem), I think linux will become more lovely.
Address:leiyin_linux@163.net
--
To unsubscribe, send a message with 'unsubscribe linux-mm my@address'
in the body to majordomo@kvack.org. For more info on Linux MM,
see: http://humbolt.geo.uu.nl/Linux-MM/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: none
1997-05-27 13:36 root
@ 1999-04-07 15:09 ` Eric W. Biederman
0 siblings, 0 replies; 2+ messages in thread
From: Eric W. Biederman @ 1999-04-07 15:09 UTC (permalink / raw)
To: leiyin_linux; +Cc: linux-mm
>>>>> "leiyin" == root <root@ns.senbell.com.cn> writes:
leiyin> I am leiyin, a software engineer in china, beijing. I am interested
leiyin> in Linux memory management these day. Since I find an ordinary user
leiyin> can easily occupy all the memory available. Though I don't think this is
leiyin> a bug. I wonder whether I can control how much memory a user can occup
leiyin> ,including swap space, or not.
yes.
The kernel interface is setrlimit, the user interface is usually
through the shell ulimit command.
The only per user limit I know of is number of processes.
The rest of the limits, stack size, virtual memory size etc, are per processs.
leiyin> Especially in AS400 OS/400 one can distribute a fixed size physical memory
leiyin> (pool) for a subsystem. If Linux can do this( I mean a fixed size memory for
leiyin> a user not subsystem), I think linux will become more lovely.
leiyin> Address:leiyin_linux@163.net
Your might want to set this in your reply to header.
Eric
--
To unsubscribe, send a message with 'unsubscribe linux-mm my@address'
in the body to majordomo@kvack.org. For more info on Linux MM,
see: http://humbolt.geo.uu.nl/Linux-MM/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1999-04-07 20:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-05-27 13:36 root
1999-04-07 15:09 ` none Eric W. Biederman
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.