Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Jul 1999 11:25:39 -0700 (PDT)
From:      Matthew Dillon <dillon@apollo.backplane.com>
To:        Noriyuki Soda <soda@sra.co.jp>
Cc:        freebsd-hackers@FreeBSD.ORG, tech-userlevel@netbsd.org
Subject:   Re: Swap overcommit (was Re: Replacement for grep(1) (part 2))
Message-ID:  <199907151825.LAA11948@apollo.backplane.com>
References:  <378D67B3.3E2A703C@newsguy.com> <Pine.GSO.3.95.990715082122.11860B-100000@jericho> <199907151738.CAA10933@srapc342.sra.co.jp> <199907151809.LAA11823@apollo.backplane.com> <199907151819.DAA11342@srapc342.sra.co.jp>

next in thread | previous in thread | raw e-mail | index | archive | help
::    -s             Print summary information  about  total  swap
::                   space usage and availability:
::
::                      allocated   The total amount of swap space
::                                  (in      1024-byte     blocks)
::                                  currently allocated for use as
::                                  backing store.
::
::                      reserved    The total amount of swap space
::                                  (in   1024-bytes  blocks)  not
::                                  currently    allocated,    but
::                                  claimed by memory mappings for
::                                  possible future use.
::
::                      used        The total amount of swap space
::                                  (in  1024-byte blocks) that is
::                                  either allocated or reserved.
:--
:soda

    It would be really easy to test this.

    Write a program that malloc's 32MB of space and touches it,
    then sleeps 10 seconds and forks, with both child and parent
    sleeping afterwords.  ( the parent and the forked child should
    not touch the memory after the fork occurs ).

    Do a pstat -s before, after the initial touch, and after
    the fork.  If you do not see the reserved swap space jump
    by 32MB after the fork, it isn't what you thought it was.

					-Matt
					Matthew Dillon 
					<dillon@backplane.com>


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199907151825.LAA11948>