Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* swap/malloc problem
@ 1996-06-07  4:00 George Grevera
  1996-06-08  4:00 ` M. van Wijk
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: George Grevera @ 1996-06-07  4:00 UTC (permalink / raw)



Hi.  I seem to have tons of swap space but can't malloc a measly
135M.  The particulars are 96M of physical memory on a DEC 3000
running OSF1 V3.0.  I don't have a /sbin/swapdefault file.

swapon -s reports:

    Swap partition /dev/rz1b:
        Allocated space:        49500 pages (386MB)
        In-use space:               1 pages (  0%)
        Free space:             49499 pages ( 99%)

    Swap partition /dev/rz3b:
        Allocated space:        20480 pages (160MB)
        In-use space:               1 pages (  0%)
        Free space:             20479 pages ( 99%)


    Total swap allocation:
        Allocated space:        69980 pages (546MB)
        In-use space:               2 pages (  0%)
        Available space:        69978 pages ( 99%)

The program that bombs is simply:

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

    int main ( int argc, char* argv[] ) {
        char* cp = malloc(135000000);
        assert(cp != NULL);
    }

I can't understand why this fails.  Thanks for your help.


George
ggrevera@gradient.cis.upenn.edu



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~1996-06-10  4:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-06-07  4:00 swap/malloc problem George Grevera
1996-06-08  4:00 ` M. van Wijk
1996-06-09  4:00 ` Dan Pop
1996-06-10  4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox