SUMMARY: Tmpfs question

From: Mike Wagner (mike_wagner@il.us.swissbank.com)
Date: Fri Oct 21 1994 - 20:29:43 CDT


Thanks to the following:

 steve@cegelecproj.co.uk (Steve_Kilbane)
 rad@getech.leeds.ac.uk
 Eckhard.Rueggeberg@ts.go.dlr.de (Eckhard Rueggeberg)
 Casper Dik <casper@fwi.uva.nl>
 Michael Ryan <mike@bakerryan.ie>
 Mike Raffety <miker>
 "Kevin A. Noll" <knoll@csl-emh2.army.mil>
 Mark Halverson x1312 <mhalvers@martin.admin.co.martin.fl.us>
 etnibsd!vsh@uunet.uu.net (Steve Harris)
 "Sam C. Nicholson !!" <scion@vanguard.symtec.com>
 tom@yac.llnl.gov
 Dan Stromberg - OAC-DCS <strombrg@bingy.acs.uci.edu>
 glenn@uniq.com.au (Glenn Satchell - Uniq Professional Services)
 blymn@awadi.com.AU (Brett Lymn)
 ken@cpatl.com (Ken Burns)

My original question:

        What is the relationship of tmpfs to main memory? According to
        the man page tmpfs is :

        "a memory based filesystem which uses kernel
        resources relating to the VM system and page cache as a
        filesystem."
        .
        .
        .
        
        "The resources used by tmpfs
        are the same as those used when commands are executed (for
        example, swap space allocation). This means that large
        sized tmpfs files can affect the amount of space left over
        for programs to execute. Likewise, programs requiring large
        amounts of memory use up the space available to tmpfs.
        Users running into this constraint (for example, running out
        of space on tmpfs) can allocate more swap space by using the
        swap(1M) command."

        The above statements make me wonder what exactly is affected,
        main memory, swap(VM) or both?

        To make my question more clear, here is an example.

        Main Memory = 256MB
        tmpfs=900 MB (Sybase tempdb 900 MB located in tmpfs filesystem.)

        Does this take up 256MB of main memory then take up the remainder
        in swap?

        I thought that tmpfs was all resident in swap and did not affect
        main memory at all? Is this correct? So the above example would
        only take up 900 MB of swap, so you would have to make sure to
        add enough swap space to handle this size tmpfs, correct?

Summary:
        The consensus is both main memory and swap are affected by tmpfs
        filesystem. My example of 900 MB tempdb in tmpfs filesystem will
        affect main memory and swap as tempdb gets filled up. The more it
        is used the more impact it will have on the system. The best way
        to think of tmpfs is like another process, active pages are in

        memory and inactive pages are swaped out.

Thanks to all,

Mike Wagner
SBC

System Engineering
Lisle, Illinois



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:09:13 CDT